If ObjectDataSource is not the answer for a large application, what is it?

Having quoted Andrew Hare's answer to this question .

Object data sources are good for small projects, but they are not scaled enough. You embed the data layer information in the user interface layer of your expression. I would suggest that you only use them for very small applications and scratch test stuff. If you make a design decision, use them to be prepared to deal with the challenges of scaling and service to the future.

Application Architecture = Maintaining Health + Scalability + ......

And I think that every article I read to start exploring application architecture used some classes to create a business data layer and used ObjectDataSource to connect the presentation layer to the business layer.

Everything seems to be wrong with me. What is the really best approach to use for the business layer and how to connect it to the presentation layer?

+4
source share
2 answers

I do not use ObjectDataSource; I personally like the control over the binding process, so I directly bind to the DataSource property and don’t use DS controls. Since DS controls when to bind or not to bind, I don’t like to use events to unbind just because I didn’t want to do it at this particular time ... It can mask some types of coding errors, which makes debugging difficult, but if there is an error , you can click on the selected, pasted, etc. event and handle the error, I suppose.

However, I do not understand why this is wrong; I'm not quite sure why it will not scale well ... if it works for you, and when you check the performance, everything is fine, then why not say it.

NTN.

+2
source

There is no doubt that ObjectDataSource simplifies the binding process.

It handles filtering, swapping, etc. with less headache.

Points to consider.

  • View (.aspx) has a link to the Business object, so it restricts some tasks such as Refactoring, the application is growing.
  • Many applications currently use IoC and ODS does not support this.
  • ODS works parameters and filtering conditions increase we should not increase. of parameters in the business, which is also undesirable.

So, if we look at all these points, ODS will not scale well.

+4
source

Source: https://habr.com/ru/post/1332706/


All Articles