Sites are defined with a Site ID. Environment management monitors the site environment using the CurrentSiteHolder
object. Whenever the site is changed, the CurrentSiteHolder
is updated with the current site.
For each request siteContext
is set using the CurrentSiteContextRuleFilter
component in atg.multisite.SiteContextPipelineServlet
. If CurrentSiteContextRuleFilter
returns a siteId
, then the siteId
is set as the site context for the entire request. The CurrentSiteContextRuleFilter
gets the current site from the CurrentSiteHolder
.
If the CurrentSiteHolder.currentSite
is empty, then the site context is not set. If the site context is not set, then environment management picks the catalog and price list based on the current user. If the site context is set, then environment management picks the catalog and price list based on the current site and user.