• Stan Hu's avatar
    Cache Flipper feature flags in L1 and L2 caches · 2db7c576
    Stan Hu authored
    In gitlab-com/gl-infra/production#928, we saw
    a significant amount of network traffic and CPU usage due to Redis
    checking feature flags via Flipper. Since these flags are hit with every
    request, the overhead becomes significant. To alleviate Redis overhead,
    we now cache the data in the following way:
    
    * L1: A thread-local memory store for 1 minute
    * L2: Redis for 1 hour
    2db7c576
feature.rb 4.73 KB