This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
We are currently evaluating Lightspeed to replace our very limited Linq-to-SQL implementation. I was hoping to understand if it suffers from the same performance limitations that L2S does with regard to parsing LINQ expression tree statements into SQL so that we can be fully prepared.
Check out this article from Omar AL Zabir: http://msmvps.com/blogs/omar/archive/2008/10/27/solving-common-problems-with-compiled-queries-in-linq-to-sql-for-high-demand-asp-net-websites.aspx As you can see, LINQ performance can be greatly increased by compiling the queries. Does this also need to be done with Lightspeed? If not, would you mind explaining why/how Lightspeed is able to overcome this limitation or perhaps why it doesn't apply to Lightspeed at all? :) Thanks! |
|
|
We don't currently support compiled queries. You can however drop down to the core API (the Query and QueryExpression classes) -- this will remove the overhead of parsing the LINQ query expression. We may review compiled query support after the 3.0 release, because 3.0 will support much more complex LINQ queries where the expression parsing overhead may be more significant than it is today. Also, if in your evaluation you find that query evaluation is causing a performance problem in your scenario, let us know and we'll be happy to work with you to find a solution. |
|
|
Thanks ivan. Do you have any examples of using the core API directly that you can link me to?
I don't exactly like the idea of forgoing the convenience of LINQ queries, but performance is utmost in our implementation. If this is a problem that is simply inherent to LINQ expression parsing that cannot be solved in any given Provider, we may have to get off the LINQ train we were so excited to board. :) Have you ran any tests on the expression parsing overhead and its impact on enterprise-level usage? |
|
|
For core API usage, see the Samples directory, in particular the SampleQueries project, and the "Querying" topic in the help file. We have tested the LINQ provider against large data sets, and I believe we found that for relatively simple queries it did not impose a significant overhead. I don't have figures though, and realistically this overhead would depend on the kind of queries you're using anyway. All I can really suggest is that you create some queries that are representative of your application, run them under the profiler and let us know if you see hotspots within LightSpeed. We can't promise to address any given issue you identify, but we do take performance very seriously and we will be happy to work with you on improving any areas where our implementation runs slow and/or helping optimise any performance-critical queries. |
|