Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Apigee x MP node in-memory cache limits

Hi All

We are checking some performance aspects of Apigee x cache internals. while checking the below page, got to know the short-lived time of cache entry in MP node is 1 second.

https://cloud.google.com/apigee/docs/api-platform/cache/cache-internals

This means, after each 1 second the entry will be removed from MP in-memory cache and will refer Cassandra for further request.

Now we have following queries regarding same:

  1. Doesn't it increase Cassandra calls which may increase cache lookup time?
  2. Does MP removes cache entry each 1 second even if lookup requests are coming in-between OR it removes after 1 second of not use?
Solved Solved
0 6 347
1 ACCEPTED SOLUTION

  1. Doesn't it increase Cassandra calls which may increase cache lookup time?
    Its a trade-off on how long the data is stored in L1 for faster access, the memory size limits within the MP nodes and the overall performance of the MP as runtime processor. On these considerations the product has  fixed on the 1-second evict policy and yes, for data lookup beyond 1 second it has to fallback on cassandra with the addtnl latency.

  2. Does MP removes cache entry each 1 second even if lookup requests are coming in-between OR it removes after 1 second of not use?
    MP evicts its data only when the memory limit is reached. The eviction are on a least-recently-used basis. (removes after 1 second of no use).

Thanks

View solution in original post

6 REPLIES 6