You can schedule sitemaps generation. Using the Scheduler in the Administration
Console, you can create a sitemaps job, or update an existing one.
For example, you might
want to include any updates that are made to your catalog each day. When the scheduled job runs, it
creates a
sitemap.xml file, and a
sitemap_storeId.xml.gz compressed file, which is based on
your catalog information.
The job generates the sitemaps and stores them in the
WAS_installdir/profiles/profile_name/temp/
directory.
If the sitemap is different from the one in the
WebSphere Commerce EAR, the
compressed file,
sitemap_storeId.xml.gz, which contains the
XML files, is then copied into the following directory:
- WC_eardir/Stores.war
- WCDE_installdir/workspace/Stores/WebContent
Procedure
-
Open the Administration Console and
select Site on the Administration Console Site/Store Selection page.
-
Click . A list of jobs that are scheduled to run is displayed.
-
Create the SitemapGenerate job:
-
Click New.
-
Create the SitemapGenerate job with the following values:
New Scheduled Job: SitemapGenerate
Parameter |
Value |
Job command |
SitemapGenerate |
Job Parameters |
Type the following optional parameters of the command into a string
representation of a URL query. For example, if you have more than one store, the URL query string
representation to specify these parameters would be
storeId_1=10001&storeId_2=10002 . The following example displays how you would
type in more than one parameter for your store:
storeId=10101&maxUrlNumber=25&storeType=B2C
Note: For extended sites stores with sales catalogs, the catalogId must be passed for the
sales
catalog:
storeId=10101&maxUrlNumber=25&storeType=B2C&catalogId=10051
- storeId
- The store ID of the store for which the sitemap is generated.
- storeType
- This parameter is used to restrict the type of store that can have a
sitemap generated. If a value is not specified, then there is no restriction on the store type of
entered store IDs.
- Can be either B2C or B2B.
- maxUrlNumber
- The maximum number of URLs a sitemap is allowed to have. If value is not
specified, the default value of 50,000 is used. A sitemap XML file cannot contain more than 50,000
URL entries.
- catalogId
- The catalog ID to generate URLs for. If no catalog ID is specified, the
master catalog ID is used.
- validation
- This flag indicates whether the generated sitemap must be validated
against the sitemap schema. By default this value is set to false.
- compareFiles
- This flag indicates whether to do a file comparison of generated sitemap
files with the files that are generated from last run. If the files are the same, no new files are
generated. Default value is true.
- sitemapView
- On an SEO enabled store, SEOSitemapView is used to
generate static page URLs. On stores without SEO enabled, this parameter can be used to specify the
name of the view that is used as the sitemap template for specified store. If no
sitemapView is specified, the default sitemap view
DefaultSitemapView is used.
- HostName
- The host name of the production server that is used to host the
sitemap.xml files. This parameter is needed when the command is executed on a
staging or remote server.
- uploadXMLToEAR
-
This flag indicates whether to upload the decompressed generated sitemap
XML files to the EAR directory (set to false by default). Both the compressed and
decompressed versions are uploaded.
- updateEAR
-
This flag allows the caller to disable the EAR update (set to
true by default). All files remain in the temporary directory.
- generateAlternateLanguage
-
This flag indicates whether the sitemap URL tags must be generated with
corresponding xhtml tags, which are set to false by default. Google's
xhtml tag indicates links of the same web content in alternate languages. For more
information about alternate languages and sitemaps, see Sitemap to indicate alternate language pages
|
Start Date |
Enter the current date. |
Start time |
Enter a time that you want to start the job for the first time. |
Schedule Interval |
Type the number of seconds between successive runs of this job. If this
parameter is omitted, the job is run only once. Typically this job is not scheduled to run regularly
and is run as needed. If you find you create many new products monthly, you might want to run it
more frequently. |
Job priority |
Enter 10 to indicate that the job is high
priority. |
-
Click OK.
Results
Your job is listed on the Scheduler Status Display page and runs at the
specified start time.