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
|
Hi , Does Lightspeed ORM support Dynamic Data? Will I be able to develop a Dynamic data web application using *.lsmodel.
Thanks. |
|
|
We do not currently have support for ASP.NET Dynamic Data out of the box, but you might be able to build dynamic data support over the existing LINQ to LightSpeed provider by annotating the partial classes with the necessary metadata (see http://blogs.msdn.com/marcinon/archive/2008/05/22/dynamic-data-samples-custom-metadata-providers.aspx). I have logged a feature request for this but it is likely to come only after the 2.1 timeframe. |
|
|
Actually, on further investigation, that link probably isn't useful after all. I'll look into this a bit more and get back to you. |
|
|
I would LOVE to see Dynamic LINQ. As an example (one of many I can give). when a person clicks on a grid, list etc, you need to re-order the data presented on various column combinaions, with a possible filter. Dynamic LINQ would be VERY useful in this scenario. Any possability of that being built into a future version?
regards Anthony |
|
|
I believe that type of sorting scenario is already supported by linq to objects. In a desktop app catch your click event and then sort and update the UI (though I dont know much how to do this in ASP.NET / web) On a side note I wrote the Dynamic Linq framework(beta) on sourceforge as an example to the Linq to SQL community on how to Dynamically create Linq queries and separately add pieces to a query and remove them. It is a layer over LINQ that tracks what you query. Behind the scenes it recreates the query every time something changes (bulk change available with BeginInit and EndInit methods to minimoze overhead) I have put that project on hold because I met "limitations"(I call them bugs) with Linq to SQL in my own project I translated and updated the Library extensively to a LightSpeed back end instead of Linq to SQL that allows my users to dynamically create queries and change them at runtime. And also have two way binding between queries so if a Parent query changes so does the child query and vice versa. MyProject called for a hierchy of this Job->Extra->Drawing->Assemblie->Part with the principles used in the Dynamic Framework you could set a filter for Jobs and get all the children that belong to the Jobs you choose. Or set a Filter on Parts and get all the Parents. Or combine filters (parents, children, even middle) so they all sync together. Its like a two way binding of queries. I have not made this library available (yet) I am slowly (wife and kids permitting) working on an IQueryable generic form of my Dynamic Lightspeed Framework. So it would work on all ORM's that support IQueryable<T>. In this implimentation I would like to work directly with the expressions and not have a layer over the Linq to allow better use of lambdas and compiler checking
|
|
|
Hi Tommy, Have you seen Paul Stovell's Bindable LINQ project? It has some similar goals including dependency tracking and auto-refresh of query results over LINQ to Objects. It's not as ambitious as your framework but you might find it interesting and/or see scope for fruitful collaboration. http://www.codeplex.com/bindablelinq if you're interested, and Paul writes about it in more detail at http://www.paulstovell.com/blog/. |
|
|
Hi Anthony, Are you referring to Dynamic LINQ in the sense of the Dynamic Query Library (http://weblogs.asp.net/scottgu/archive/2008/01/07/dynamic-linq-part-1-using-the-linq-dynamic-query-library.aspx)? If so, I believe that should work with the LightSpeed LINQ provider automatically because it just translates text queries into LINQ expression trees and feeds them into whatever provider is at hand. (Obviously subject to the limitations of the LightSpeed LINQ provider.) This is different from Dynamic Data though -- Dynamic Data is about constructing ASP.NET UIs on the fly based on the data model. Or have I misunderstood your comment? |
|
|
That project sounds Really interesting! keep us posted, wife, and kids permitting
regards Anthony |
|
|
Any more word on support for the ASP.NET Dynamic Data bits? I'm converting over a live ASP.NET MVC site where we use Dynamic Data for the admin screens. If this can be done with Lightspeed, that would certainly help. Thanks much. Dan |
|
|
Hi Dan, We have prototyped support for Dynamic Data but we have tested it only in a very limited context. I'll see what we can do in terms of packaging up that work and getting it into the nightly builds, though please note that such an initial drop would be primarily for testing and feedback -- it will probably be a couple of weeks before we are able to work on getting it to production quality. |
|
|
Thanks for the fast reply, Ivan. I'm using the Personal version right now. Would the nightly builds work with that version? If it does, I'll be sure to download and get you that testing and feedback. :) Dan |
|
|
Yes, nightly builds of the free edition are available from http://www.mindscape.co.nz/Products/LightSpeed/nightlybuilds.aspx. However due to pressure of other stuff we're not going to be able to get the dynamic data bits packaged up in time for tonight's build, so don't rush out and download just yet *grin* -- we'll aim to get it done in the next couple of days and I will post here when it's available. |
|
|
Hello Dan and everybody else who has expressed an interest in ASP.NET Dynamic Data on LightSpeed. We are now shipping a preliminary version of this in current nightly builds, available from http://www.mindscape.co.nz/products/lightspeed/nightlybuilds.aspx (Express Edition) or the store (retail editions). We want to emphasise that this is very much at the prototype stage for testing and feedback. We know there are limitations and issues and things that just don't work yet. (That's why we're mentioning it on this thread rather than announcing it on the blog.) We will be addressing these ourselves over the next few weeks but we would also love to hear from users with real world Dynamic Data scenarios. However, we do ask you to treat this as proof of concept: don't expect everything to be working, and don't rely on it for production use. With that disclaimer out of the way, here's how to use it: 1. Create a Dynamic Data Web Application. 2. Add a LightSpeed model (or reference a project containing an existing model, provided that project is built with LINQ support). 3. Add a reference to Mindscape.LightSpeed.Web.DynamicData.dll. 4. Go into each page in the PageTemplates directory and add the following directive: <%@ Register TagPrefix="ls" Assembly="Mindscape.LightSpeed.Web.DynamicData" Namespace="Mindscape.LightSpeed.Web.DynamicData" %> 5. For each page in the PageTemplates directory, locate the <asp:LinqDataSource> element and change it to <ls:LightSpeedLinqDataSource> (obviously changing the close tag as well). Don't modify the attributes or content of these elements. 6. Go into Global.asax.cs and find the place in RegisterRoutes where it says "IMPORTANT: DATA MODEL REGISTRATION". Replace the commented-out RegisterContext line with the following: LightSpeedContext<XxxUnitOfWork> context = new LightSpeedContext<XxxUnitOfWork> where XxxUnitOfWork is the LINQ unit of work type generated by your model (i.e. Xxx is your model name). (You can of course create the LightSpeedContext<T> as a static member of the Global class, rather than a local -- this might be useful if you were planning to add custom code that used the LightSpeedContext -- or whatever. And of course you can, and probably should, initialise it from configuration rather than from code.) Note that the context MUST be a LightSpeedContext<TUnitOfWork>, not just a plain LightSpeedContext. Your dynamic data site should now work -- at least up to a point! Once again, remember this is not a complete implementation and is intended only for feedback. If you're not prepared for things to simply Not Work, please don't use this version -- watch the blog and we'll make an announcement when it's a bit more polished! We look forward to your feedback and suggestions. |
|
|
Thanks, Ivan. It looks like this is working with the 4.0 DynamicData bits? I had my old application using the DynamicData for MVC bits, so this is going to take some rework to run the one application partitioned to use the right code for each section now. I'll keep you posted as that migration happens. |
|
|
It was built against 3.5 SP1 -- but yes, the core ASP.NET framework dynamic data bits rather than anything MVC-specific. |
|
|
Ivan, Thanks for your team's work towards integration with DynamicData. Can you give an update on the status? Our development team is currently evaluating ORMs (we're moving from NetTiers) and DynamicData integration is a key component. We were getting excited about the Entity Framework, but through some testing with VS2010 Beta 2 and .NET 4 we've found that there's still a lot to be worked out before it's ready for prime time. Thanks, Dan |
|
|
FWIW, I've been using Dynamic Data in my LS app since Ivan mentioned that it was available. It really is as simple as he posted, and it works wonderfully. |
|
|
Hello Dan (dmc76), We have made a significant number of bug fixes to Dynamic Data since 2.2, and also have added support for making Dynamic Data aware of LightSpeed validations. See http://www.mindscape.co.nz/forums/Post.aspx?ThreadID=2211&PostID=6274 or the updated help file for info about how to enable validations. We'd therefore strongly recommend using the nightly build or 3.0 beta for Dynamic Data. We haven't yet investigated Dynamic Data 4.0 or Futures, but we plan to support 4.0 and would expect to address any compatibility issues with DD 4.0 after we ship LightSpeed 3. Hope this answers your question -- if there is any specific info you need about the status of LightSpeed Dynamic Data support, let us know. |
|