?
Solved

Limitations / Problems with ObjectDataSource

Posted on 2009-07-06
7
Medium Priority
?
286 Views
Last Modified: 2013-12-17
Guys,
Can anyone help me in understanding the Limitations / Problems with ObjectDataSource in .NET 2.0 and 3.5 framework? I have heard that this is not a best practice to use ObjectDataSource. We are going to create a new application with SOA and SaaS model. We want the application be very much flexible and easily adoptable.
Please suggest me.
0
Comment
Question by:saj_37uk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
7 Comments
 
LVL 18

Accepted Solution

by:
Richard Lee earned 1000 total points
ID: 24787571
ObjectDataSource Limitations:

1. Tightly coupled to databound control.
2. Tightly coupled to select/update/delete methods
3. Event lifecyle difficult to follow especially when interacting with other complex controls.
4. Event firing out of your control.
5. Hard to extend application.

A better loosely coupled and more flexible data access layer is appropriate for your SOA and SaaS model. To increase reliability and decrease development time an ORM such as LINQ or Entity Framework can be used.

I would strongly advised against using ObjectDataSource a model such as the following could be used.

             <-- Lightweight DTOs                <-- ORM DTOs
Presentation    <--    Business     <--    LINQ/Entity Framework/etc    <--    Data Source
-------------------------------------------------------------------------------------------------------
 Presentation           Business                                    Data Layer
     Layer                     Layer
-------------------------------------------------------------------------------------------------------
0
 

Author Comment

by:saj_37uk
ID: 24787729
Thank you very much!
Do you have any other suggestion for using with SOA & SaaS model? We are planning to include CSLA framework.
0
 
LVL 18

Assisted Solution

by:Richard Lee
Richard Lee earned 1000 total points
ID: 24787877
I am not a fan of the CSLA framework however it works and caters for concurrency.

To support loose coupling & separation of concerns (SoC) you may want to look into a UI design pattern/framework. Since you are using ASP.NET the ASP.NET MVC Framework springs to mind. http://www.asp.net/mvc.

This ensures that all logic that handles functionality can be seperate and therefore can be handled by a service outside of the UI. You can also look into the Model View Presenter (MVP) pattern. Almost the same but you can choose your preference.
0
 

Author Comment

by:saj_37uk
ID: 24788205
Thank you very much for your open suggestions. I'm accepting this as a solution of my query.
0
 
LVL 18

Expert Comment

by:Richard Lee
ID: 24788441
Thanks but I don't think you prompted to close the solution rather than accept.
0

Featured Post

NFR key for Veeam Agent for Linux

Veeam is happy to provide a free NFR license for one year.  It allows for the non‑production use and valid for five workstations and two servers. Veeam Agent for Linux is a simple backup tool for your Linux installations, both on‑premises and in the public cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The object model of .Net can be overwhelming at times – so overwhelming that quite trivial tasks often take hours of research. In this case, the task at hand was to populate the datagrid from SQL Server database in Visual Studio 2008 Windows applica…
This document covers how to connect to SQL Server and browse its contents.  It is meant for those new to Visual Studio and/or working with Microsoft SQL Server.  It is not a guide to building SQL Server database connections in your code.  This is mo…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question