Guys,I am a fan of both CSLA.net and EnterpriseLibrary.
I was wondering if somebody has tried to integrate the two and may be post a complete solution showing the integration.
What I would like to do whether it makes sense or not is to use some of the blocks that the Enterprise Library provides.
What the enterprise Library is missing is a business Block.CSLA.Net seems the perfect fit.
In my view if we could integrate the two it would fantastic.
Without going into much details I would like to integrate the following
DataAccessBlock
Exception Handling
Logging Block
Caching Block
Configuration Block
Leave out the new validationblock (EL 3.0)
and use CSLA .net as the business Block if you like
Also I would like to use the Power Collections in addition to the BindingLIst provided by CSLA.net.
Is this feasable?
I have some questions and obviosly i am not expecting to have all answered by it would be great?
Would it be possible to make the CSLA.net more of a plug in framework.
Like Make the Security-Validation-BrokenRules - Collections etc...
all separate class Libraries .
This in my view would create a more flexible use of the CSLA.net and vastly improve it's usability.
Sometimes I have also wondered whether the usage of a DTO would have been a more effective way to move data across.and Yes have a validation Component deployed in each logical tier that would be used by both UI for responsiveness and BO for server side validation.
May be I am missing the obvious but arent we creating a chatty object by going between the UI and BL for each field validation?
Are the objects stateless or stateful when going out of process?
What about the myth that the CSLA is too heavy (reflection) and Undoable classes to be used in a web Application?
Thanks guys I am exploring the wild world of Architecture and I have so many doubts.I would be grateful if you could clarify some of them that I have exposed here.
EL is a bloated pig that I wouldn't use even if told to do so. It sells itself as this great helper that is doing so much for you but 9 out of 10 time you don't need it. For isntance if you look at how simple it is to do logging in the first place you'll find that you can get the same results without bloating your config file.
I find it to be sledge hammer being used on finishing nails in most places and have usually ripped it out resulting in increased performance and a much smaller foot print and rarely has there been more code to maintain, in several cases it's actually been less.
If you want to learn about architecture read Martin Fowlers Refactoring book, particularly the section about speculative generalities. Also, right tool for right job, build for what you need, don't throw stuff that's out there because it's the current buzz-word or trend, etc. Have a business model before you worry about architecture. Have a vision before you worry about designing a system. Follow these rules and you'll do great.
Also if you are seriously thinking about intergrating the two, now you've produced coupling, so no matter what you'll always have to have references to both assemblies, and not all projects will require CSLA and not all project will require EL.
There are numerous posts and threads about this on the forum and my blog
http://www.google.com/search?as_q=enterprise%20library&as_sitesearch=lhotka.net
Hey ,i can see some anger in you.Chill!!!.
Like many people out there I am on a learning curve.I have read martin Fowler books.However Those theoritic concept are really good if
1) you have the oppurtunity to build a framework from scratch
2) you already familiar with Patterns and concepts and you can easily visualize them in a real world scenario.
Why is CSLA so good and thought me so much.Because we have a pratical example as they say "A picture is worth a 1000 words".
I think all those books out there about agile Development ,TDD etc .. without a prototype example solution that you can actually see what they mean are very confusing for the novice programmer venturing in the architecture world.
Again I am a big fan of CSLA but in my view there are some shortcomings:
Nothing prevents me for decoupling it but it would be nice if
Validation-Security -Broken Rules -Were all Separate Assemblies.
Especially collections should be on their own.
Sorry but I think the EL is a great product ,is free ,open source and if you dont like write you own Logging and exception block or Configuration block which you use anyway as its in the System.Configuration.
Please provide constructive points.
Thanks
Copyright (c) Marimer LLC