Skip to content

Commit

Permalink
docws(middleware/session): Add note about IdleTimeout requiring save …
Browse files Browse the repository at this point in the history
…using legacy approach
  • Loading branch information
sixcolors committed Sep 20, 2024
1 parent 9ec2b30 commit 684dc8a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/middleware/session.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,10 @@ To convert a v2 example to use the v3 legacy approach, follow these steps:
2. **Retrieve Session**: Access the session store using the `store.Get(c)` method.
3. **Release Session**: Ensure that you call `sess.Release()` after you are done with the session to manage its lifecycle.

:::note
When using the legacy approach, the IdleTimeout will only be updated when the session is saved.
:::

#### Example Conversion

**v2 Example:**
Expand Down

0 comments on commit 684dc8a

Please sign in to comment.