|
Hi,
My apologies if I put this in the incorrect forum
I got the book on expert business objects, and they use the CSLA.NET framework. Now I read many negative reviews on this framework after buying the book And alot of people say that we should rather use DDD (Domain-Driven Design). What exactly is DDD? And why choose it above CSLA.NET? Are there any good books/online articles to read that explains this for beginners and how to implement it?
What other similar commercial/opensource frameworks are available to look at?
Has any one used CSLA.NET? And comments positive/negative?
Regards,
Brendan
|
|
|
|
|
These are two somewhat orthogonal (or complementary) items.
CSLA.NET provides a harness that eases the persistence, state snapshot, and business-rule tracking. This entire harness reflects the methodology that Lhotka uses to create his applcations. You can compare this harness-as-philosophy to Taligent's MVP harness or Clifton's Application Automation Layer. Normally, you have to buy into this lock, stock, and barrel to adopt these types of harnesses.
DDD attempts to provide a set of guidelines by which a software development team can produce in anticipated and repeatable ways the decomposition of a business model into an object-oriented structure. My exposure to this started with Coad's Domain-Neutral Component and Modelling in Color, supplemented by Nicola, et. al.'s Streamlined Object Modeling. The most recent valuable entry in this list is Evans' Domain-Driven Design: Tackling Complexity in the Heart of Software.
So, CSLA.NET embodies a philosophy regarding application construction. DDD embodies "best practices" for modeling a business domain.
The Application Automation Layer: Introduction And Design[^]
Modeling in Color[^]
Streamlined Object Modeling[^]
Domain-Driven Design[^]
"we must lose precision to make significant statements about complex systems."
-deKorvin on uncertainty
|
|
|
|
|
Thanks for the answer. So you would advise staying away for CSLA.NET and taking a DDD approach? There is a .NET book about DDD where the guy explains it with .NET. I am thinking of buying it. I am currently reading the CSLA.NET book. Do you use a DDD approach?
|
|
|
|
|
.NET Enthusiast wrote: So you would advise staying away for CSLA.NET and taking a DDD approach?
That's not what he said. The two items are complementary, so you should incorporate the bits of both that work for you. Possibly the best skill you can learn is how to analyse ideas, and see how they fit in a particular instance - don't blindly accept that one way or another is the only way to do things in all situations.
"WPF has many lovers. It's a veritable porn star!" - Josh Smith As Braveheart once said, "You can take our freedom but you'll never take our Hobnobs!" - Martin Hughes.
My blog | My articles | MoXAML PowerToys | Onyx
|
|
|
|
|
I think that you need to stop worrying about the .NET focus and read more on object-oriented design. You can, then, translate that to many different OO languages. Furthermore, it will help your programming more than just learning from .NET-focused studies.
Once you do that, harnesses like CSLA.NET will make a lot more sense to you.
"we must lose precision to make significant statements about complex systems."
-deKorvin on uncertainty
|
|
|
|
|
Can any one help me to make a benchmark for checking CPU and RAM performance.
|
|
|
|
|
Hi All,
I would like to build a three tier application in which the DAL layer is based on the provider model design patter, and the BLL will be coded to an abstarct layer interface.
As an example in the DAL I would have
IProductsProvider class, IProducts class
ICategoriesProvider class, ICategories class
the BLL will be coded against the ProductsProvider and ICategoriesProvider.
An actual implementation of the IProductsProvider could be SQLProductsProvider or XMLProductsProvider
How is it possible to implement a similar pattern with strongly-type datasets?
As an example I would like to define a kind of strongly-typed datatable and tableadapters or datasets...
IProductsTableAdapter
IProductTable
ICategoriesTableAdapter
ICategoriesTable
and code the BLL versus these interfaces, and then have
SQLProductsTableAdapter implements IProductsTableAdapter
SQLProductsTable implements IProductsTable
this is to allow the switch of different providers without having to rewrite the BLL code.
Thanks
|
|
|
|
|
I am a OOD applier, I am working on a company that they provide two-tier (application-database) solution, I reviewed most of existing source code that most business logic are located in stored procedure, I feel that is not a good idea, and now, some colleague want to change because of difficult to maintenance but because it need change the thinking approach so some colleague become anti-OO.
Because of company solution is two-tier, is stored procedure a good approach in this environment?
P.S. Because of the vender lock-in pattern, the provided solution at least contain client application tier.
|
|
|
|
|
Putting in all Biz Logic in Stored Procedure is not a good approach.
Data Filtering logic should be put in Stored Procedure.
Whereas the Biz Logic and other data processing logic should be in Biz Layer.
I can understand your situation. It is not going to be a easy task of changing peoples mindset overnight.
However, slowly slowly once the developers sees the benefits of layered architecture, they are going to change.
My suggestion for you is to start coming up with Biz Components and changing stored procedures and then get into layered architecture for your application.
|
|
|
|
|
I would disagree with Robin, but only because of the types of apps I am currently working on. I work mostly with batch processes, not transactional data. Therefore almost all our business logic resides in stored procs. We recently tried to move some of the logic back into a c# business layer but the performance was so abysmal we went back to stored procs.
When working with large, batches on data then the database is the place for the business logic. If you are working on a transactional system, manipulating small amounts of data often then the business layer is the best option. Use the right tool for the job!
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Yes, I would definitely agree. Almost all of the time we put our business logic in a C# business layer. But sometimes there is no substitute, in terms of performance, for a bit of business logic in the stored procedures.
Adam
|
|
|
|
|
Correct, I agree with you.
Sometimes we cannot afford a layered architecture. It is not practical also.
Architecture should be based on Application demand.
Thanks for pointing this out.
|
|
|
|
|
So, I'm making a program where you can input a ton of data.
I already made a new form for each type of data, but for many there are parts where you can input a variable number of entries.
Like for one kind you input some invariable data and then add any number (0, too) of data sets which all have the same amount of necessary inputs.
So far I placed a tab control in the each of the forms and inside put all the input controls.
For the variable data sets I put some controls to add the needed inputs and show them in a list view.
If you don't like one, you can remove it again.
Now I'm wondering if I should outsource the input for these data sets to a new form each, this would also make it easy to edit them and not have to remove one and then add a new one.
Considering that I already have 7 forms of different data types, each with a tab control of 3-5 pages, on each page different data to input, would the be overload for the user?
|
|
|
|
|
Hey, it would depend on the type of form. If it is related to a specific task, like filling up any application form, then its fine.
|
|
|
|
|
I ALWAYS (well 98% of the time) force the user to input via a seperate form, never in a list control. I have seen so many question here related to managing the DGV events.
The biggest issue I would see is managing the transactions if data entry across multiple screens (if this is a requirement) try and design the forms to encapsulate all the required data entry for a type.
I consider a 3-5 tab controls about the max I want to put on a single form before the poor thing has to struggle.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Thanks.
I made them small forms you can just click away with enter or escape. It was necessary to edit anything anyway.
|
|
|
|
|
I'm trying to determine what software and components, etc, to use to build a program that runs my bank accounts and budget, and I'm choosing products that would allow me the option to sell the product one day if I wanted to.
Not in the first version, but later, I'd like for it to allow an installation on a second machine to access the data and run the program using the data on the original computer. How can I build from the beginning to make this functionality as easy as possible to add later. (I am aware that Windows itself will need to allow file sharing)
Thank you.
|
|
|
|
|
You can look at the peer-to-peer capabilities in .NET. Here's an article[^] right here on Code Project.
"we must lose precision to make significant statements about complex systems."
-deKorvin on uncertainty
|
|
|
|
|
Depends a bit on where that second computer is located. Is it on your local network, or is it connected through the internet?
You could install SQL Express[^]. That has the advantage that you wouldn't have to allow file-sharing.
SQL Server and .NET are a tried combination, it should be easy to access/modify data, to create/restore backups etc.
Good luck
|
|
|
|
|
Thanks guys. The sharing of the database would definitely only be behind a firewall, although theoretically possibly on different subnets. I like the quality of not needing File Sharing to work.
On SQL Express, someone said it
1)is not "in-process" so there is "a hassle deploying the service, etc"
2)is server-less (said as if it is a negative)
What do these things mean?
modified on Saturday, July 25, 2009 12:12 PM
|
|
|
|
|
@copec,
If you plan on building something with a certain amount of system topological complexity as you're saying, you need more than a cursory understanding of the technological concepts involved. Especially if you plan on supporting this application in the future.
Both of these terms (and many more) can be found on the Internet. I suggest some reading on your part to understand the choices of the tools that you'll choose to use in your application.
These links will, hopefully, help you in understanding the problems that you're facing:
SQLite[^] (Embedded database)
FirebirdSql[^] (Open sourced RDBMS)
Data Architecture[^] (Challenges of data architecture)
Learning more will help you ask better questions.
Skaal!
Curtis.
"we must lose precision to make significant statements about complex systems."
-deKorvin on uncertainty
|
|
|
|
|
copec wrote: 1)is not "in-process" so there is "a hassle deploying the service, etc"
This means that it doesn't run in the same memory space. I fail to see how this has much to do with deployment.
(In short, a DLL usually shares the space, some external app doesn't)
copec wrote: 2)is server-less (said as if it is a negative)
Microsoft Access is "serverless", SQL Express isn't. Sometimes you want something that acts as a server (app is always there, ready to talk to lots of clients) or server-less (a Word-document, or an MSAccess database).
(In short; a serverless app writes the data locally, whilst a client would send it to the server, and let the server take care of the writing)
copec wrote: What do these things mean?
It means that this person probably doesn't like SQL Server. If he's the customer, you'd best investigate an alternative.
Tutorials for the most frequently operations can be found here[^], in case you want to take a peek
"Some mainframe users still wonder if SQL Server is reliable enough for them. We're a nuclear power plant—how much more reliable do they need it to be?" -- Janice Hoerber[ ^]
|
|
|
|
|
Thanks for the info, Eddy.
So, I think I understand.
a) using a db with server capability is what front-end/back-end means. They are independent and have to talk to one another (using tools like ADO.NET and LINQ to SQL?)
b) there can be multiple clients that connect to a back-end, which is a db with server capabilities
c) the db's server ability handles the read, write, change, etc calls from a front-end and sends back whatever is asked for
d) if I want to allow more than one PC to connect to the same db, I need a db with server capability
Is that right?
I'm guessing that choosing a server-capable db means more complicated coding of the program, but would it also mean more difficult deployment (for me) or installation (for the end users), or are there other negatives?
Is there any worth to using serverless now (for ease) but coding in such a way that transitioning to server-capable later isn't too bad?
Thanks for the link. It's bookmarked and I'll be spending hours there it looks like.
Eddy Vluggen wrote: It means that this person probably doesn't like SQL Server.
He did recommend SQL Server Compact edition, but said that it is serverless. (I tried to confirm this at the MS website but couldn't tell either way) If they're coreect and I understand what you've said, this person must've overlooked that I would want to be able to have multiple clients.
modified on Saturday, July 25, 2009 2:16 PM
|
|
|
|
|
copec wrote: a) using a db with server capability is where the concept of front-end/back-end comes from
b) there can be multiple clients that connect to a back-end, which is a db with server capabilities
c) the db's server ability handles the read, write, change, etc calls from a front-end and sends back whatever is asked for
I don't know if that's the origin of the word, but this is indeed, broadly, what a database does.
copec wrote: d) if I want to allow more than one PC to connect to the same db, I need a db with server capability
In general, yes
copec wrote: I'm guessing that choosing a server-capable db means more complicated coding of the program, but would it also mean more difficult deployment (for me) or installation (for the end users), or are there other negatives?
There are several variables. One thing to consider is that a server is an actual application that is "always" running when the computer is powered on. That can be a bit of a performance-impact. I haven't written much installation-scripts lately, but I guess that it's as easy to install as the .NET Framework itself, just ticking the box being a prerequisite.
The central question should be whether you need a database-server (as a shared data-repository) or a local datastore (a private data-repository)
Microsoft Access has a friendly interface, and is often abused as a server. You'll find lots of rants on Access, because it's widely used. Best thing of all is that there's an upsize-wizard that upsizes the tables of your Access-database to SQL Express/Server, once you're in need of such a migration.
|
|
|
|
|
Thanks again Eddy.
Eddy Vluggen wrote: The central question should be whether you need a database-server (as a shared data-repository) or a local datastore (a private data-repository)
For now, for sure, I will only need a local datastore, but I can see that I would like to be able to (later) add the ability to have multiple client front-ends for one the datastore. Can I develop the first version in such a way that I allow myself the ability to later "plug in" multi-client ability with a minimum of rewriting, etc.?
|
|
|
|
|