Google Cloud Professional Cloud Database Engineer — Question 142

You are using Memorystore for Redis to cache frequently accessed data and improve your application's performance. Recently, your application is experiencing sudden spikes in latency when interacting with the Memorystore for Redis instance. Upon checking the logs, you discover a high number of "evicted keys" messages. You want to reduce the occurrences of latency spikes and their impact on the application. What should you do?

Answer options

Correct answer: C

Explanation

The correct answer is C because scaling the Memorystore instance to a larger memory size will help accommodate more data and reduce the likelihood of key eviction, which directly addresses the latency spikes. Increasing the TTL (A) may not solve the underlying memory issue, while redeploying the application (B) and enabling read replicas (D) do not directly resolve the eviction problem.