Skip to content

fix(settings): handle unavailable OPcache status and clarify sizing advice - #66149

Draft
joshtrichards wants to merge 1 commit into
masterfrom
jtr/fix-OPcacheSetupRecs
Draft

joshtrichards wants to merge 1 commit into
masterfrom
jtr/fix-OPcacheSetupRecs

Conversation

@joshtrichards

@joshtrichards joshtrichards commented Nov 2, 2026 •

Copy link
Copy Markdown
Member
  • Resolves: #

Summary

Improve OPcache setup diagnostics without changing the existing cache-full gate, exact key-limit comparison, or interned-string usage/sizing thresholds.

  • Run independent configuration checks before early returns, preserving their findings.
  • Return immediately when opcache_get_status() fails, preventing invalid array access and false interned-string warnings.
  • Match opcache_get_status exactly in disable_functions and explain when usage checks are skipped.
  • Distinguish missing statistics/settings from zero values; report unavailable data explicitly.
  • Skip dedicated interned-string buffer checks when its configured size is zero.
  • Clarify exhaustion recommendations while retaining their purpose and sizing context.
  • Correct comments about effective key limits, cache_full coverage, and wasted-memory restart conditions.

Admin-visible behavior

Failed status retrieval no longer produces misleading interned-string exhaustion advice.

Unavailable usage statistics or sizing values are reported explicitly where needed. A configured zero-sized dedicated interned-string buffer does not itself produce a warning.

Disabling opcache_get_status through disable_functions now produces an explicit warning; previously, usage checks were skipped silently.

TODO

  • ...

Checklist

AI (if applicable)

  • The content of this PR was partly or fully generated using AI

Run independent OPcache configuration checks before returning from usage checks so their findings are preserved when status retrieval is disabled or fails.

Return immediately when opcache_get_status() returns false, avoiding invalid array access and false interned-string exhaustion warnings.

Distinguish unavailable usage statistics and numeric settings from
zero values. Skip dedicated interned-string buffer checks when its
configured size is zero, and report unavailable sizing information
when observed usage indicates pressure.

Match opcache_get_status exactly in disable_functions and report when usage checks are skipped.

Clarify key-limit and shared-memory recommendations while preserving their purpose and sizing context. Revise comments about cache_full and wasted-memory restart conditions.

Assisted-by: Copilot:gpt-6.1-sol

Signed-off-by: Josh <josh.t.richards@gmail.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants