ADO.Net Overview

Sunday, August 30, 2009

Background
• ADO (ActiveX Data Objects) was originally designed as a connected and tightly coupled model.
• ADO was more appropriate for the client/server architectures and not designed for a distributed and n-tier environment.
• ADO was not hierarchical like XML structures.
• ADO object was not well factored.

What is ADO.Net
• ADO .NET is a collection of classes, interfaces, structures, and enumerated types that manage data access from relational data stores within the .NET Framework
• ADO.NET collections are organized into the following namespace.
- System.Data,
- System.Data.OleDb,
- System.Data.SqlClient, etc.
• ADO .NET is an evolution from ADO.

Managed Providers
- Merges ADO and OLEDB into one layer
- Each provider contains a set of classes that implement common interfaces

Initial managed provider implementations:-
-ADO Managed Provider: provides access to any OLE DB data source
- SQL Server Managed Provider: provides optimal performance when using SQL Server
Data Access Style
ADO.NET access data into two ways.
- Connected mode: Forward-only, read-only mode
- Application issues query then reads back results and processes them.
- ADO.Net uses DataReader object in connected mode.
- Disconnected mode
- Application issues query then retrieves and stores results for processing of the data.
- Minimizes time connected to database
- ADO.Net uses DataSet object in disconnected mode.

Remote Objects

Saturday, August 29, 2009

In remoting there are two kind of remote objects are available.
1. Client activated Objects – A client activated objects is created and destruction is done by the client application. An instance of the remote object is created when client invokes new operator on the server objects. This instance lives as long as client requires it.

The client object will be destructed once its existence is no longer required by any client.

2. Server activated objects – A server activated object’s lifetime is managed by the remote server and not by the client which instantiates the objects. Server activated objects are not created by the client when it calls new operator. They are created when client invokes proxy method.

There are two kinds of server objects.
Single Call
– Single call objects handle only one request from a client. Single call objects are stateless objects.
Singleton – Singleton objects instance serves multiple clients. Singleton objects are stateful objects.

 
 
 
Your Ad Here