Skip to content

A simple memory cache using buffers and byte limits

License

Notifications You must be signed in to change notification settings

smith-xyz/buffer-cache

Folders and files

NameName
Last commit message
Last commit date
Jul 4, 2024
Mar 20, 2024
Mar 20, 2024
Mar 20, 2024
Mar 20, 2024
Mar 20, 2024
Mar 20, 2024
Mar 20, 2024
May 11, 2024
Jul 4, 2024
Mar 20, 2024
Jul 4, 2024
Jul 4, 2024
Jul 4, 2024

Repository files navigation

buffer-cache

A simple memory cache using buffers and byte limits

Usage

const cache: BufferCache<number, TestingType> = new BufferCache([[{ id: 1 }]], {
  ttl: 1,
  maxByteSize: 900,
  resizeStrategy: 'LARGEST',
});

Resize strategy

Able to choose between removing largest, first, last of the cache.

About

A simple memory cache using buffers and byte limits

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published