NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Determining the "AppBase"

Each Application Domain has an associated "AppBase" and configuration file. The AppBase is a directory that serves as the root directory when probing for assemblies on disk. The configuration file contains config information specific to the code running in the domain.

The scenarios above show that we must provide some flexibility in creating the Domain/AppBase/Config file. We can't always tie it to the site, nor can we always tie it to an individual html page or a directory on the web server. Instead we provide default behavior that is appropriate for most scenarios and allow developers to customize this behavior for more advanced scenarios.

By default the IE Host creates an AppDomain per site and sets the AppBase to the site directory. This handles many common scenarios, including the "Joe's Flower Shop" scenario described above.

Developers can change this default behavior by pointing to a configuration file using the LINK tag in their html pages. The syntax is:

<LINK REL=Configuration href="http://stevenpr/myapp/app.cfg">

The IE host will place all pages that point to the same configuration file in the same domain. The ability to create an AppDomain at something other than the site level is needed to support scenarios where there is more than one app per site, like the HumanResources and some ISP hosting scenarios.

If the HumanResources example above uses ASP+ it is likely they will have application config files in both the Payroll and Benefits subdirectories. These config files will be the same ones pointed to by the LINK tag in the HTML pages. This way, we unify the config of the server portions of the app with the client portions of the app. Stated differently, the concept of "application" as defined by the server portion is consistent with that of the client portion.