silverstripe / silverstripe/developer-docs

Wrong documentation for caching ?

Open
#34 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

affects/v4 complexity/low complexity/medium type/docs
Dominant language
No language data
Stars
7
Forks
74
Avg merge
1d 14m
Merged PRs (30d)
6

Description

Documentation for caching states on line 133 that :

You can also set your lifetime to 0, which means they won't expire

Actually, this seems to remove cache, TTL will be set to false in normalizeTtlmethod in Symfony\Component\Cache\Simple\AbstractCache

Not setting any ttl looks like the way to achieve wanted behavior for me. Do you agree ?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open the linked Caching.md and inspect the statement around line 133. Compare its description of a zero lifetime with Symfony\Component\Cache\Simple\AbstractCache::normalizeTtl, then update the documentation to match the verified behavior and clarify how to configure non-expiring cache entries.

Written by the indexing model from the issue text.

Assessment

Tech stack
symfony
Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.