Hello!
I'm trying the new Entity framework and I must say that I observe an utterly strange performance result. Is there a way to submit my solution for investigation at Microsoft?
Best regards,
Henrik Dahl
Hi Henrik,
Please briefly describe your scenario and the expected result and send me the solution for investigation to nvalluri at microsoft dot com.
regards,
Naveen Valluri,
I've now submitted the stuff to you.
Do you think you have a chance to look at it in short time - I'm really looking forward hearing from you?
Best regards,
Henrik Dahl
Naveen Valluri,
Have you managed to observe the same amazing consumption of computational resources when running the solution?
Best regards,
Henrik Dahl
Sorry for the delay in response. Naveen is actually out sick today. We'll try to connect with him and get back to you as soon as we can. Given that I don't have the details of your situation, I can't speak to it, but I will say that one of the things we are working on during this development milestone is a significant push for performance improvements... The difference in beta 3 should be really noticeable for some scenarios.
- Danny
Hello Danny!
OK.
I imagine Naveen will be sick for only a few days. I may easily wait for that and let him to recover in peace!
It sounds good with significant performance improvements. In the current case it took multiple hours to insert a singular row in a singular table so I think that here there's really room for multiple orders of magnitude of performance improvements.
Despite it's not really the subject of this thread, do you know of a rough estimation of availability of beta 3, is it for instance assumed to be released during the year of 2007?
Best regards,
Henrik Dahl
The intention is to line up beta 3 of the EF with Orcas RTM. So, yes, we intend that it will ship sometime before the end of this calendar year, but of course there are lots of things that could change between now and then.
- Danny
Daniel,
Yes, it's obvious, but thank you for sharing this.
I look forward hearing from Naveen as he'll be back again.
Best regards,
Henrik Dahl
Hi Henrik,
Thanks for your patience. We did observe the delay in inserting the record for the first time and this is in part because the framework compiles the model files. Any queries, inserts or updates after that is in sub-second range. In the current milestone, we have been working on improving the performance in this area. We tried your scenarios against our latest bits, which you will see delivered as part of Beta 3 in late November and the performance has significantly improved. The time to compile the model files is reduced to 20 seconds. Again, to reiterate, this is only the first time that CRUD operation goes to the server . Even for this, we are working towards making this happen during design time, so that the cost isn’t there at runtime.
Thanks,
Naveen
Given that view compilation is the source of the problem, you can also pre-compile your views even in beta 2, and then you will have a big hit during this initial step, but at runtime that hit will go away. I've been meaning to write a blog post on how to do that, but haven't gotten to it yet. Suddenly I feel motivated--now if only I could get the time to do it... The clue I'll give you now is to look at the commandline options on edmgen where there's a generateviews or something like that. This will output code that is a compiled version of the views which the EF uses for queries and updates. You can compile that into your assembly, and then things should get much faster at runtime.
- Danny