wrapped TTL can return nil from lookup-or-miss

Description

This is a known issue for the TTL cache since it can invalid an entry on lookup and so the double lookup performed by through-cache and lookup-or-miss can cause a "hit" immediately followed by an invalidating "lookup" resulting in nil.

core.memoize already has spin logic to account for this. Similar logic should be added to lookup-or-miss (and the possibility of invalidation be noted on some other API functions, although the spin will not be added to those).

Environment

None

Activity

Show:
Sean Corfield
August 25, 2019, 1:26 AM

In 0.8.1 release.

Fixed

Assignee

Sean Corfield

Reporter

Sean Corfield

Labels

None

Approval

None

Patch

None

Priority

Major