feat: mutex for InstagramEventsJob [CW-2447] (#7828)

This commit is contained in:
Shivam Mishra
2023-09-04 16:32:13 +07:00
committed by GitHub
parent 9ebabb9832
commit 336584c95a
3 changed files with 20 additions and 4 deletions

View File

@@ -37,5 +37,6 @@ module Redis::RedisKeys
## Sempahores / Locks
# We don't want to process messages from the same sender concurrently to prevent creating double conversations
FACEBOOK_MESSAGE_MUTEX = 'FB_MESSAGE_CREATE_LOCK::%<sender_id>s::%<recipient_id>s'.freeze
IG_MESSAGE_MUTEX = 'IG_MESSAGE_CREATE_LOCK::%<sender_id>s::%<ig_account_id>s'.freeze
SLACK_MESSAGE_MUTEX = 'SLACK_MESSAGE_LOCK::%<conversation_id>s::%<reference_id>s'.freeze
end