Processing of site accessibility is divided between two components:

Active Site Evaluation

The SiteManager determines whether a site is active through its SiteStateProcessor component, which is referenced by the SiteManager’s siteStateProcessor property—by default, /atg/multisite/DefaultSiteStateProcessor. This component implements interface atg.multisite.SiteStateProcessor. The Oracle ATG Web Commerce installation provides one implementation class, atg.multisite.DefaultSiteStateProcessorImpl. This class defines the method isSiteActive(), which evaluates the RepositoryItem of a given site and returns true (active) or false (inactive).

DefaultSiteStateProcessorImpl has several properties that let individual servers determine whether a site is enabled and active, regardless of its site repository settings:

Property

Description

ignoreEnabled

If set to true, nullifies the site’s enabled property setting and enables the site.

Default: false

ignoreOpenDate

If set to true, nullifies the site’s openDate property setting, and leaves the site’s opening date unspecified.

Default: false

ignoreClosingDate

If set to true, nullifies the site’s closingDate property setting and leaves the site’s closing date unspecified.

Default: false

In its default implementation, isSiteActive() reads these properties when it determines whether a site is enabled and active. By default, these Boolean properties are set to false; in this case, isSiteActive() reports to the SiteManager on a site’s availability solely on the basis of its repository settings. For example, if a site’s closingDate precedes the current date, the SiteManager regards the site as inactive and denies access to it. However, if the siteStateProcessor’s ignoreClosingDate property is set to true, the SiteManager ignores the closingDate setting and regards the site as active.

Customizing Active Site Evaluation

You can modify and extend the logic of active site evaluation as follows:

Customizing Redirection

The SiteContextPipelineServlet redirects requests for disabled and inactive sites through its DefaultInactiveSiteHandler property. This property is set to a component that is based, by default, on the class atg.multisite.InactiveSiteHandlerImpl. This component redirects requests to the appropriate URL. You can customize redirect handling as follows:

Note: If you use your own implementation of the SiteStateProcessor interface, you should also customize the DefaultInactiveSiteHandler to reflect those changes. The SiteStateProcessor only determines whether a site is active; it supplies no information why the site is inactive.