System Pipelines and Controllers
The SiteGenesis JavaScript Controllers (SGJC) application includes system pipelines or controllers that are not called by a URL or another pipeline but directly by Salesforce B2C Commerce. Their names can't be changed.
Default
These controllers
are in the app_storefront_controllers
cartridge in the
controllers
folder.
These pipelines are in the
app_storefront_core
cartridge in the Application
group.
- Default-Start: called when no pipeline name is provided. Although you can't change the node name, you can customize its contents.
- Default-Offline: called when a site is offline. Although you can't change the node name, you can customize its contents.
Error Handling
These controllers are in the
app_storefront_controllers
cartridge in the
controllers
folder.
These pipelines are in the
app_storefront_core
cartridge in the Application
group.
- Error-Start: called as a general error page.
- Error-Forbidden: called if a secure cookie has an unexpected value.
- OnSession-Do: called when a new session starts. The pipeline
prepares promotions or price books based on source codes or affiliate
information in the initial URL.Important: For performance reasons, keep this pipeline short.
-
OnRequest-Do: called for each page request on the storefront. This pipeline is called both for cached and non-cached pages. For performance reasons, keep this pipeline short.
Important: For performance reasons, keep this pipeline short.
For controllers, you can also use standard JavaScript error handing.
For pipeilnes, you can also use an Error node that points to a custom subpipeline if you want to take a specific action when an error occurs.
SEO
These controllers are in the
app_storefront_controllers
cartridge in the
controllers
folder.
These pipelines are in the
app_storefront_core
cartridge in the Application
group.
- RedirectURL-Start: called for redirects to a new URL.
- SiteMap-Google: called to download site map for a standard home page.
Rendering Pipelines with SEO Support:
These controllers are in the
app_storefront_controllers
cartridge in the
controllers
folder.
These pipelines are in the
app_storefront_core
cartridge in the Catalog
group.
- Search-Show: renders a full featured product search result page.
If the
http
parameterformat
is set toajax,
only the product grid is rendered instead of the full page. - Product-Show: renders a full product detail page. If the
http
parameterformat
is set tojson
the product details are rendered as JSON response. - Product-ShowInCategory: renders the product detail page within the context of a category.
This pipeline, in the Content group, is in the SiteGenesis Storefront Core cartridge.
- Page-Show: renders a content page based on the rendering template configured for the page or a default rendering template.
Link pipeline (Deprecated):
This pipeline, which forwards calls to other pipelines, supports legacy code where content assets link to specific pipelines. For new code, link to the respective pipeline directly (for example, Search-Show or Product-Show). You can also create links within content assets directly in Business Manager.
These pipelines, in the Application group, are in the core SiteGenesis cartridge.
- Link-Category: links to a category page from within a content asset.
- Link-CategoryProduct: links to the product detail page for a specific category from within a content asset. Use this if a product is assigned to multiple categories, for example, a standard and a sales category.
- Link-Page: links to a page from within a content asset.
- Link-Product: links to a product detail page from within a content asset.
Reserved
These names can't be used for custom pipelines or controllers.
- directURL-Hostname: called by B2C Commerce to handle URL mappings, such
as static mappings and mapping rules, which are configured in Business
Manager. This pipeline is critical to site performance, because it's
frequently called in case of exploit scans. The input for the pipeline
is the original URL to redirect the user from.Note: Salesforce strongly recommends that you follow these rules when using this pipeline:
- Use no or only a few database calls
- Use simple (static) template response
- cache the result page
- SourceCodeRedirect-Start: is the pipeline hook for a source code redirect.
- PowerReviews-XmlProductDescription: renders the product XML
description based on the given ID.
Input: pid (required) - product ID
Internal Pipelines
These pipelines are used internally by B2C Commerce and not the SiteGenesis application. They can't be edited. You can't view them in Studio or any other development tool even though they appear in the Page Cache Information tool or other debugging tools.
- __SYSTEM__Slot-Render: internal pipeline called when a content slot is rendered.
- __SYSTEM__Slot-Request: internal pipeline called when the content for a content slot is requested.