Skip to content

Document session, sales-channel context, and cart lifecycles with clear config boundaries#2308

Draft
Copilot wants to merge 2 commits into
mainfrom
copilot/docs-missing-session-lifetime-docs
Draft

Document session, sales-channel context, and cart lifecycles with clear config boundaries#2308
Copilot wants to merge 2 commits into
mainfrom
copilot/docs-missing-session-lifetime-docs

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 27, 2026

The docs did not explain how Symfony session lifetime, Store API context lifetime, persisted sales-channel context, and cart expiration interact, which made login/cart persistence behavior hard to reason about. This update adds a single, centralized explanation that separates each lifecycle and its controlling config.

  • Added lifecycle overview in guides/hosting/performance/session.md

    • New section: Session, context, and cart lifetime
    • Clarifies that these lifecycles are independent and can expire at different times.
  • Added UML sequence diagram (Mermaid)

    • Visualizes flow across browser session cookie, Symfony session, sales-channel context token, and cart token.
  • Added config-to-behavior comparison table

    • Distinguishes each setting by scope, token/data affected, and expiration effect:
      • framework.session.cookie_lifetime
      • framework.session.gc_maxlifetime
      • shopware.api.store.context_lifetime
      • shopware.sales_channel_context.expire_days
      • shopware.cart.expire_days
  • Added concise risk/capacity guidance

    • Notes security tradeoffs of longer lifetimes on shared devices.
    • Notes infrastructure impact (e.g., higher Redis memory usage) for longer retention windows.
sequenceDiagram
    participant Browser
    participant Symfony Session
    participant Sales Channel Context
    participant Cart
    Browser->>Symfony Session: Store session cookie
    Symfony Session->>Sales Channel Context: Resolve context token
    Sales Channel Context->>Cart: Load cart by token
Loading

Copilot AI changed the title [WIP] Add documentation for session lifetime in Shopware Document session, sales-channel context, and cart lifecycles with clear config boundaries May 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Docs]: Missing Session Lifetime Documentation

2 participants