prebid-server icon indicating copy to clipboard operation
prebid-server copied to clipboard

Module LRU Cache

Open bretg opened this issue 9 months ago • 1 comments

The committee discussed providing caching services to modules in the context of https://github.com/prebid/prebid-server/issues/3512

We agreed that another important component would be a controlled cache local to Prebid Server. Some modules may have a local cache hit ratio high enough to help overall latency.

Requirements:

  1. use of a local cache must be optional - something that module vendors and host companies decide.
  2. the amount of data each module is allowed to store locally must be configurable.
  3. the backing store URL used by each module must be configurable and support a macro for retrieval key

Note that the 51Degrees module implemented an LRU cache that might be applicable more broadly:

https://github.com/51Degrees/Java-Device-Detection/blob/cbc9a1acf55a863054530152fe42daa9bde2ed07/device-detection-core/src/main/java/fiftyone/mobile/detection/cache/LruCache.java#L67

Looking for community members to help flesh out a technical proposal.

bretg avatar May 22 '24 15:05 bretg