用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/ben-manes/caffeine --skill audit-lifecycle命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
基于 SOC 职业分类
正在显示 SKILL.md
| name | audit-lifecycle |
| description | Analyze shutdown, close, and GC-of-cache lifecycle correctness |
| context | fork |
| agent | auditor |
| disable-model-invocation | true |
Analyze the cache for defects during shutdown, close, and garbage collection of the cache instance itself.
Assume at least one shutdown or lifecycle race exists. If your analysis yields zero findings, re-examine scheduler/executor lifecycle and in-flight operations during close — explain specifically why no race is possible.
Operations racing with close/cleanup: get/put/compute during cleanUp() or GC? close() state transition? Operations after close()?
Scheduler lifecycle: Does the scheduled future prevent cache GC? Can scheduler fire after cache is collected? Is the task cancelled on close?
Executor lifecycle: Reference cycle between cache and executor? RejectedExecutionException handling when executor is shut down?
Removal listener drain on shutdown: Are pending notifications delivered or dropped? Notifications lost if executor shuts down first?
In-flight operations during shutdown:
Multiple close calls: Is close() idempotent? Concurrent close() corruption?
Finalizer / Cleaner interactions: Reference queues outliving the cache? Reference queue processing accessing dead cache?
jcache manager/cache close: Is teardown symmetric with setup — the OSGi context-classloader swap applied on destroy/close as on create/get; in-flight futures awaited; user Closeables (writer, loader, listeners, expiry) closed exactly once under the right classloader?
For each defect: state the lifecycle transition, provide a concrete scenario, state the observable incorrect behavior.