Documentation: it is not clear how the seed relates to the cache policy

Description

It was observed on Slack that for a FIFO cache, the seed has wording that talks about order but a hash map will have no "order".

Clarify in the docstrings and in the README that the seed may be arbitrarily ordered for building the "initial" version of the cache.

Environment

None

Activity

Show:
Sean Corfield
October 19, 2019, 11:15 PM

The docstring seems very clear about this and I can't find any other places where there's a conflict between how the seed is described and how the cache policy is described.

Sean Corfield
October 19, 2019, 11:12 PM

The FIFO factory docstring is very explicit about this already:

If the associative
structure can guarantee ordering, then the said ordering will define the
eventual eviction order. Otherwise, there are no guarantees for the eventual
eviction ordering.

and:

If the associative
structure used as base can guarantee sorting, then the last limit elements
will be used as the cache seed values. Otherwise, there are no guarantees about
the elements in the resulting cache.

Cannot Reproduce

Assignee

Sean Corfield

Reporter

Sean Corfield

Labels

None

Approval

None

Patch

None

Priority

Major