Announcement

Collapse
No announcement yet.

Mono 2.11.3 Packs In Microsoft's Entity Framework

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • phoronix
    started a topic Mono 2.11.3 Packs In Microsoft's Entity Framework

    Mono 2.11.3 Packs In Microsoft's Entity Framework

    Phoronix: Mono 2.11.3 Packs In Microsoft's Entity Framework

    Running fresh off $12M USD in funding, Miguel de Icaza's Xamarin has released their fourth preview release of Mono 2.11...

    http://www.phoronix.com/vr.php?view=MTE1OTQ

  • uid313
    replied
    Originally posted by CARMEN View Post
    Surporised information. But it is not possile to be open on .NET
    Why wouldn't it be possible to be open while on .NET?

    Sounds like FUD.

    Leave a comment:


  • CARMEN
    replied
    Surporised information. But it is not possile to be open on .NET

    Leave a comment:


  • yogi_berra
    replied
    Originally posted by frantaylor View Post
    good for them, manufacturing value from nothing

    Doesn't affect MY bottom line nor YOURS either
    So you like working for free?

    Leave a comment:


  • droste
    replied
    Originally posted by frantaylor View Post
    You know that query execution time depends on the number of rows IN THE TABLE not the number of rows returned from the query, right? If you have 15 million rows in a table, it's going to take a LOT longer to select one row than a table with just a few entries?
    No not right, that is not how database queries work. The time the database spends to find the row is not the only thing that costly. The overall speed depends on how many data is in the table, what data you want from the row, how you search for one row and on how you transport the data to the application.

    A few examples:
    - Imaging the following DB2 SQL query: SELECT myPrimaryKey FROM myTable FETCH FIRST 1 ROWS ONLY. This will be fast no matter how many entries are in the table.
    - When you only query data that is indexed the database can highly reduce disk I/O (the slow part).
    - If you have a network in between you and the database preselecting the data you need can highly reduce your network traffic.

    Have you ever actually used a database? And not every program written presents you with a website viewable via the internet. There are many programs out there that just present data from a DB within a thin client to the user. It's not a good idea to always send all information you have to the client, because it slows down the client really fast.

    Leave a comment:


  • kazetsukai
    replied
    Originally posted by frantaylor View Post
    "CREATE TABLE myData (K INTEGER AUTO_INCREMENT PRIMARY KEY, D VARCHAR(262144))"
    d = JSON.encode(myObject);
    sql.execute("INSERT INTO myData(D) VALUE (?)", d)
    key = sql.lastInsertedKey ...
    ---
    sql.execute("SELECT D FROM myData WHERE K=?", key)
    myObject = JSON.decode(sql.fetch)
    ---
    This is where my forehead slammed into my palm.

    Originally posted by frantaylor View Post
    really if you want an "entity framework" or an "ORM" for a quick demo application you can just use a two-column table and JSON
    Before the railing.... For the record, I don't use ORM. I rolled my own interfaces to make MySQL and Oracle databases _look similar_ in basic access, but I still write my SQL.

    Your JSON example is an extremely poor solution to problems ORM strives to solve. It isn't as simple as object preservation, you have to be able to get the data out, and compare it to other data structures. Lets say I'm an online book retailer and I want to look at all Mystery books under $10. Using your solution, I'm basically going to have to load the entire database into RAM and then de-serialize each and every record (parsing text, allocating memory) it back into an object, before I can finally filter it by the criteria I'd like.

    Even a basic key-value pair schema (which is what Microsoft's "Entity Framework" does) is a better option... and with that, good luck when you have schemas with trillions of rows.

    Real ORM is a developer written class that acts as an extension to an ORM framework, implementing very specific interfaces. This class handles all custom logic for your database schema in an optimized and schema-specific manner. Once you've done this work, you can reap the benefits of not having to do it again... every query being optimized for you, automatically. Your solution solves only problems that personal websites encounter (and poorly), not something with decent volume.

    Leave a comment:


  • frantaylor
    replied
    Originally posted by droste View Post
    Why would I try to do that? I don't see a reason to get all users and especially not with all colors. You would setup the color to be lazy loaded so you don't have the overhead when you just want the user.
    You know that query execution time depends on the number of rows IN THE TABLE not the number of rows returned from the query, right? If you have 15 million rows in a table, it's going to take a LOT longer to select one row than a table with just a few entries?

    That's what the ORM is for ;-) You don't do it, it does it for you.
    NO, ORM does NOT manage your data for you. It does NOT make decisions about how to store your data based on how much data you have. ORM stands for "Object-Relational Model". ALL it does is turn your object into SQL rows and then back again. It does NOT pick your indexes (it probably makes a primary key, but that's not enough for your color table), it does NOT tell you that your color table is a lousy design.

    There a only a few applications that have to handle the workload facebook or google have.
    How do you know this? What about sites that have finite budgets for computer hardware? They must accomodate their users with limited hardware so they must squeeze performance wherever they can.

    If you actually want to enforce constraints on a busy database, you OFFLOAD the constraint calculations to another system. You can do this by making the data available to other apps via SOAP or some such, and write a small server that does the constraint calculations and then stores the data in the database.

    You don't want your database engine to be calculating constraints! You want your database to be fetching and storing data.

    suddenly changing some datatypes or formats for example
    This is another reason for using a SOAP-like service for applications: you don't WANT your applications to know or care about how the data is stored in your database. If you expose SQL then you will be constantly updating your apps as you change the schema, unless you use SQL views, but they slow things down, too.

    Also SQL data permissions often don't line up with your application. You will encounter situations where SQL permissions are not able to adequately represent your security requirements. In these cases you must write an intermediate agent to do the security for you, which would be part of the SOAP engine I mentioned above.

    Separating the mechanics of the data storage from the application is a good design principle. If your stated worry is real, this is how you deal with it.

    Oh and by the way: did you understand why I said "you have choices" when I described the "favorite colors" requirement? It's because your way of doing it is the obvious and slow one. Like I said, bitmap indexes can convey the same information and they are much much faster than your method.
    Last edited by frantaylor; 08-15-2012, 10:55 AM.

    Leave a comment:


  • Tgui
    replied
    Oh and anyone here use Hibernate? I have for some very large projects. The cost needed for performance HQL tuning/lazy loading etc was more than made up in a build environment that supported quick and easy schema changes which in turn made it super easy to fold in new devs quickly with a minimal amount of domain specific training to get them up and running.

    Of course you can't just toss ORM at a large project and hope it works!!!

    Leave a comment:


  • Tgui
    replied
    I just installed one of our MVC3 apps to Linux/Apache/Mono. It worked. If Mono saves me money on server OS costs, I'm all for it. As far as EF is concerned, I see it like Rails. If the ORM helps me solve small-med projects fast I'll use it. I'm happy to see EF on Linux!

    Leave a comment:


  • ciplogic
    replied
    Originally posted by frantaylor View Post
    In other words it's the new "Microsoft Access": quickly create inefficient applications that use huge resources, are unscalable, and must be re-written from scratch when they need to be scaled.

    Toys for boys
    I don't want to be a MS poofter, but it seems that you never understand what MS Access was and/or what Entity is. If you will say that Visual Studio Lightswitch is the MS Aceess, it would make some sense (even is a loose comparison).
    If you meant that Entity is the new ADO.Net (which is probably what you think of), I agree, it is built on top of Ado.Net, it behaves well with Linq and do a lot of things transparently.

    What is so unscalable with Entity? Entity is used inside of Bing, which even is not Google, is still scalable, isn't so? You can't execute it from multiple threads? The overhead of CLR reflection is too big?
    Did you try to make a 64 thread application and run it on a machine like this one?

    Even it would be not so scalable (even this wording seems is fairly reduntant), most of the time the database backend (the RDBMS itself) has to be performant, not the thin client querying the response.

    Or for you Mono is not scalable, and based on that, you mean that Entity will be just another bloat...
    This means that you run most likely a browser that it's JS runs at 1/2 of speed of Mono, in the best case (when is close to C like coding), and its SQLite database doesn't scale, means that we all running slow inefficient applications, right, right?
    So for this reason you use text based console browser?

    At the end, are you a developer? Are you a troll that it happen to dislike Mono?
    If you're using Android phone, are you against Android VM which is much slower than Mono For Android. If you're using Ubuntu, Fedora and not only, a lot of your tools are written in the slow Python which have Global Lock, which this is for really unscalable and slow in multithreaded applications.
    Last edited by ciplogic; 08-15-2012, 04:08 AM.

    Leave a comment:

Working...
X