301 URL redirection has been included as part of the SEO solution for WebSphere Commerce Feature Pack 3. If a URL is changed either by WebSphere Commerce or a business user, a redirect is automatically generated between the old and new URLs.
URL redirects have been implemented for the following cases:
- When the URL of a catalog entry, catalog group or static page is updated, a redirect is automatically generated between the old and new URLs.
- When an extended site specific URL for a catalog entry or catalog group is created, the asset store URL is duplicated to the extended site and then a redirect is created between the extended site duplicate of the asset store URL and the new URL
- When an extended site specific URL is cleared for a catalog entry or catalog group, a redirect is created between the extended site URL and the asset store URL
In all of the above cases if the URL of a catalog entry or catalog group is updated multiple times then all previous redirects are updated to point to the latest URL for that catalog object. In this way redirection chains are avoided.
URL redirect traffic
Traffic statistics are recorded for individual redirect mappings. These statistics are held in the SEOREDIRECTTRAFFIC table.This table holds:
- The last used date of individual redirect mappings
- The number of times that those redirect mappings are used
While there is no out-of-the-box user interface to view these statistics, these values are useful:
- A custom user interface can be created in order to monitor when search engines, affiliate links, and customer's personal bookmarks are still referring to old URLs for your catalog entries or catalog groups
- For determining when to delete old URLs from the database in order to improve system performance.
In order to help with performance, redirect traffic data is not sent to the database on each use of a redirect rule. Instead that data is stored in a cache, and is only flushed to the database once a certain number of redirect usages has occurred. This number is configurable by referring to the redirectHitCountBatchUpdateSize parameter in the SEORuntime section of the wc-admin-component.xml infrastructure configuration file.
Removing unused URLs
Out of the box Scheduler : CleanSEOURLS
The CleanSEOURLS job command is used to clean up the tables related to search engine optimization (SEO) URL redirects and SEO URL keywords. An SEO URL redirect rule is deemed obsolete if the date the rule was last used by an incoming HTTP request has exceeded 60 days. This number is configurable by modifying the infrastructure component configuration file (wc-admin-component.xml). Once a redirect rule is deemed obsolete the original url keyword that was used in that rule is also deleted. These are the URL keywords that are marked as "inactive" when a redirect rule is created.