Is CSLA right for me?

Is CSLA right for me?

Old forum URL: forums.lhotka.net/forums/t/7864.aspx


artsd posted on Saturday, October 24, 2009

I sure hope some expert out there has the patience to read this and give me some advice. I am suffering from "paralysis by analysis" for a new project. I need to make a decision and get going NOW.

I have a large line-of-business product that uses a 12 year old code base implemented in C++ using DCOM/MTS/ODBC. We have a DCOM business object layer that enforces our object/property security using domain users/groups configuration (in other words, we can configure object CRUD and property read/read-write privs by domain user or group). 95% of our business objects implement no additional business logic except the security enforcement -- they are really just a way to get to the data access layer to perform CRUD against SQL Server using a MTS (COM+) component we wrote using ODBC. Our existing client application enforces many other business rules such as required fields and default field values for new records. To give you an idea of scale, there are over 800 tables and over 200 data entry forms, most of which have multiple tabs of data entry fields.

My requirement is to modernize this entire application. I have no desire to carry forward any existing code. But I must carry over the existing DB schema as is (of course I can make additions but for backward compatibility, I cannot make drastic changes).

The new client will be XAML based (might be Silverlight or WPF -- I prefer Silverlight but not sure yet if we can live with certain sandbox limitations). There is also the possibility of having a client with a subset of the full functionality implemented in ASP.NET for delivery to mobile devices (iPhone, Android, Windows Mobile 6.5+ -- things with decent browsers -- not just WAP).

Not only do I need to support my own XAML application, I also need to expose a traditional web service API (don't know if REST or SOAP yet) that can be consumed by third parties (our customers really). This means that all core functionality of my current application needs to be implemented in the service / BO layer (I am thinking of things like required fields which are currently enforced in my client code).

I have the old 2005 CSLA book. I have read a ton on various DAL, ORM, and BO libraries. Of course there are lots of DAL/ORM out there but not too many complete BO frameworks like CSLA. I have been experimenting with MS Entity Framework and ADO.NET Data Services and .NET RIA Services -- they seem like decent DAL that easily exposes web services but require a lot more work to turn into proper BO layer.

Wow. If you are still reading than I can't thank you enough.

Do you think CSLA is right for me?

Is there anything else I should look into (Spring.NET, etc.)?

Thanks in advance for your suggestions!!!

RockfordLhotka replied on Saturday, October 24, 2009

fwiw, this is exactly the type of application that CSLA .NET is intended to support.

If I understand correctly, you need to have a way to create a new business layer without altering the existing database. CSLA will help you create that new business layer, interacting with a data access layer that maps your object domain model to/from the data structure. You can create that DAL with an ORM or not as you choose.

And you need to build 2-3 types of public interface on top of your business layer. So the business layer needs to be consumable from Silverlight/WPF, XML services and ASP.NET. This is one of the strengths of CSLA .NET, in that it is designed to help you build a business layer that can support these various types of interface, while encapsulating your business logic in the business layer.

While I'm clearly biased, what I'm getting at is that you seem to be describing the exact type of application scenario that I designed CSLA .NET to support.

artsd replied on Saturday, October 24, 2009

Thanks Rocky. I think my next step will be to buy the 2008 book, download the latest code, and experiment with just a couple of tables to get a very narrow but deep look at the functionality (ie, try to think of all functionality I need from the new BOL and see what it takes to implement some of the core features I need such as object/property security, required fields, default field values, data filtering, etc.). If that works out well, I will buy the Silverlight video series and then go crazy for a several months. Thanks!

JoeFallon1 replied on Monday, October 26, 2009

I have a large application that uses the following technologies:

ASP.Net
Windows Forms
SOAP
Windows Mobile Browser

All of this is supported by CSLA. The mobile app was very easy to implement as we simply had to run it server side using CSLA BOs and then output mobile html controls.

HTH
Joe

 

Wbmstrmjb replied on Monday, October 26, 2009

I did make it all the way through your post and I too concur that your type of scenario is what CSLA was designed for. I doubt you will find functionality missing as this framework has been built up over time with so much input. Not to mention if you do run across an issue, Rocky almost always responds to every post. How many frameworks have their creator on hand to answer your questions?

FWIW,
Mike

Copyright (c) Marimer LLC