16.01.2013 Views

Microsoft Sharepoint Products and Technologies Resource Kit eBook

Microsoft Sharepoint Products and Technologies Resource Kit eBook

Microsoft Sharepoint Products and Technologies Resource Kit eBook

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

110 Part II: SharePoint <strong>Products</strong> <strong>and</strong> <strong>Technologies</strong> Architecture<br />

Saving Database Space<br />

The content database of a site includes a documents table that contains a record for<br />

each page created in a site. Considering the number of sites <strong>and</strong> pages that Windows<br />

SharePoint Services can support, the number of records in this table can be<br />

quite large. Even though the number of records is large, Windows SharePoint Services<br />

keep the overall size of the table low by keeping each record in the table relatively<br />

empty by default. When a page is created by using a template, the record in<br />

the content database for that page contains only the location of the template used to<br />

create the page. The record does not contain any customization data for the page.<br />

The customization of each site’s page occurs only during the rendering process.<br />

During this process, a navigation control looks to the URL of the page <strong>and</strong><br />

finds the name of the site. The control uses the site name to find customization information<br />

in the content database <strong>and</strong> makes these customization changes before the<br />

page displays. In essence, each page that is based on the same template is the same,<br />

but users do not realize this because of customizations made during the rendering<br />

process.<br />

Increasing Performance<br />

The use of templates also allows ASP.NET pages to run as they were designed. Normally,<br />

an ASP.NET page is read <strong>and</strong> then saved to a DLL file on the local computer.<br />

Subsequent requests for that page are h<strong>and</strong>led by running the DLL off the local file<br />

system. In Windows SharePoint Services, this is called direct mode. Site pages that<br />

are based on templates run in direct mode. A DLL only needs to be created for each<br />

template instead of for each site’s version of the page. It would not be practical to<br />

have a DLL read into memory for each site’s version of a page.<br />

The Effects of Customization<br />

The performance enhancements in the architecture of templates <strong>and</strong> site pages<br />

based on templates are lost once a site page is customized. Once the code of a site<br />

page is edited <strong>and</strong> saved, it can no longer use the template to load.<br />

Once this occurs, Windows SharePoint Services changes the site page’s record in<br />

the documents table of the site content database. It replaces the location of the template<br />

in the site pages record with a copy of the entire page. Also, because only templates<br />

can run in direct mode, from that point on the page must be run in safe mode.<br />

The Web.Config File<br />

The Web.config file is an XML-based text file that contains configuration information<br />

for ASP.NET services. There are multiple Web.config files in Windows Share-<br />

Point Services. In a Windows SharePoint Services deployment, Web.config files are<br />

contained in the following folders within the file system:

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!