Skip to content

Commit

Permalink
Fix: gc-stream wasn't given a limit correctly, causing it to grow inf…
Browse files Browse the repository at this point in the history
…inite (#47)

Well, in the end, the Redis OOM kicked in. But .. yeah ..
  • Loading branch information
TrueBrain authored Jul 17, 2021
1 parent 4a85da6 commit fcd4308
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion master_server/database/redis.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def __init__(self):

async def add_to_stream(self, entry_type, payload):
await self._redis.xadd(
"gc-stream", {"gc-id": -1, "type": entry_type, "payload": json.dumps(payload)}, approximate=1000
"gc-stream", {"gc-id": -1, "type": entry_type, "payload": json.dumps(payload)}, maxlen=1000
)

async def check_session_key_token(self, session_key, token):
Expand Down

0 comments on commit fcd4308

Please sign in to comment.