You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, used_requests is stored in Redis with an expiration matching the user's subscription period_end. However, this approach lacks a method for tracking historical data unless we implemented heartbeats, which would be inefficient.
The proposed solution is to store the user's period_end in Redis. When this timestamp is <= now(), a historical entry should be added to a stats table in Supabase. Following this, the used_requests key in Redis would be reset to zero.
The text was updated successfully, but these errors were encountered:
Currently,
used_requests
is stored in Redis with an expiration matching the user's subscriptionperiod_end
. However, this approach lacks a method for tracking historical data unless we implemented heartbeats, which would be inefficient.The proposed solution is to store the user's
period_end
in Redis. When this timestamp is<= now()
, a historical entry should be added to a stats table in Supabase. Following this, theused_requests
key in Redis would be reset to zero.The text was updated successfully, but these errors were encountered: