Loading
Salesforce から送信されるメールは、承認済ドメインからのみとなります続きを読む

Understanding URL Diversity and increasing cache hit rates in B2C Commerce

公開日: Jul 31, 2025
説明

URL Diversity

URL diversity involves using different URLs to serve similar content.
This practice, while beneficial for tracking and analytics, can hinder caching efficiency.

The URL is treated as a whole when creating its signature, meaning every parameter affects the unique cache entry.
Each unique URL forces the server to process requests individually, increasing load times.


Examples:

 

Positional Parameters

Using positional parameters rather than key/value pairs can enhance security and SEO. Additionally, this approach can improve cache configuration and effectiveness by creating more predictable and efficient caching mechanisms.

 

AspectPositional Parameters (Path)Key/Value Pair Parameters (Query)
URL StructureParameters are included in the URL path.Parameters are included in the query string.
Example URLhttps://example.com/products/electronics/laptops/123https://example.com/products?category=electronics&subcategory=laptops&id=123
Caching EfficiencyCan lead to efficient caching if URLs are well-structured and predictable.Query parameters can cause varying URL signatures, making caching less predictable.
For example: colour=1&cat=2 VS cat=2&colour=1. Same output, but different URL signature.
SEOGenerally better for SEO as search engines favor clean, hierarchical URLs without excessive parameters.Query strings can be indexed by search engines, but too many parameters or irrelevant ones might dilute the keyword relevance and reduce SEO effectiveness. It's important to keep query strings concise and relevant.

 

“Web Adapter Cache Key Ignore” Feature

Salesforce B2C Commerce Cloud offers this feature to manage caching issues from URL diversity. Administrators can specify which query parameters to ignore, improving caching efficiency.

How It Works:

  • Purpose: Enhances caching by ignoring certain URL parameters.
  • Activation: Log into Business Manager, go to Administration > Global Preferences > Feature Switches and search for the Web Adapter Cache Key Ignore toggle. 
  • Configuration: Enter parameters to ignore in a comma-separated list.
  • Default Behavior: Disabled by default, ensuring intentional and controlled caching behavior changes.


Impact on Cache ‘Miss and Store’:

Enabling this feature reduces unique cache entries, improving cache hit rates and performance by serving more requests from the cache. This can be monitored via Reports and Dashboards, helping track cache hit versus ‘miss and store’ rates for optimization. Regular audits of ignored parameters against performance reports enhance site performance and user experience by ensuring efficient content delivery.

    解決策

    Best Practices for URL Management in B2C Commerce

    To maintain efficient caching and effective tracking:

    1. Minimize URL diversity: Use consistent URLs without unnecessary parameters. For any extra (but required) parameters, use the ‘Web Adapter Cache Key Ignore’ feature.
    2. Review URL patterns and caching rules regularly: Monitor URL generation and caching to identify improvements.
    3. Selective ignoring with ‘Web Adapter Cache Key Ignore’: Only ignore parameters that do not affect content functionality. Parameters affecting output should not be ignored.
    4. Audit ignored parameters periodically: Cross-reference with ‘Reports and Dashboards’ to track cache hit/miss rates and overall performance.

    Implementing these practices enhances site performance and user experience while maintaining valuable insights from analytics and other tools, crucial for a responsive and optimal B2C Commerce storefront.

    ナレッジ記事番号

    002277452

     
    読み込み中
    Salesforce Help | Article