Аудит повторного входа в Caffeine-кэше

testing

audit-reentrancy is a Claude Code skill that audits user-supplied callbacks in a Caffeine cache for re-entrancy defects — deadlocks, state corruption, and exposure to partially-constructed objects. It covers seven callback types: CacheLoader (load, loadAll, reload), Weigher, Expiry, RemovalListener, EvictionListener, mapping functions passed to compute/computeIfAbsent/merge, and JCache counterparts including CacheEntryListener, CacheWriter, EntryProcessor, and ExpiryPolicy. For each callback the skill enumerates every lock held at invocation time — evictionLock, CHM bin lock, synchronized(node) — and then traces what occurs when that callback calls get, put, remove, compute, size, clear, cleanUp, or asMap(). Each (callback, cache-method) pair is assessed for potential deadlock through lock re-acquisition or ordering violations, state corruption from mid-mutation re-entry, and observable incorrect behavior. Where the cache already defers work to defend against re-entrancy, the skill verifies that the mechanism is complete.