Easy application deployment and maintenance

Applications are often made up of several components:

1. Web Pages
2. Windows forms-based components
3. Web services
4. Components housed in DLLs
The .NET Framework makes it possible to install applications that use some or all of these components without having to register DLLs (using regsvr32.exe) or to create Registration Database (also known as the system Registry) entries. The .NET Framework makes it easy to deploy applications using zero-impact installation often all that's required to install an application is to copy it into a directory along with the components it requires. This is possible because the .NET Framework handles the details of locating and loading components an application needs, even if you have several versions of the same component available on a single system. All of this is possible because the .NET Framework records extra information about an application's components — the extra information is called metadata. A component of the .NET, Framework, the Class Loader, inspects an application's metadata and ensures that all of the components the application depends on are available on the system before the application begins to execute. This feature of the .NET Framework works to isolate applications from each other despite changes in system configuration, making it easier to install and upgrade applications.
Once an application is running on a system, it is sometimes necessary to change certain traits of the application, such as its security requirements, optional parameters, and even database connections. .NET Framework applications use a configuration model based on application-configuration files. A configuration file is a text file that contains XML elements that affect the behavior of an application. For example, an administrator can configure an application to use only a certain version of a component the application relies on, thereby ensuring consistent behavior regardless of how often the component is upgraded.
The following code shows an ASP.NET's basic configuration file; the file is called web.config:













This code shows that the ASP.NET application will have page buffering on (pages will be sent to clients only when the page is completely rendered), and that ASP.NET will track ndividual clients' session information (as shown in the pages tag). This code also demonstrates how to define a custom configuration key, called dsn — within the appSettings section, which applications have access to through the TraceSwitch class.

0 Comments: