feat(bot-platform): migrate BotRegistry to Redis Streams consumer group
Build & Test (NowChessSystems) TeamCity build finished
Build & Test (NowChessSystems) TeamCity build finished
Replace pub/sub subscribe with XREADGROUP on bot game-start stream. Remove dual-write from EventPublisher.publishGameStart. Consumer group: bot-platform-consumer, XACK after forwarding. Poll loop uses emitter identity to prevent thread leak on re-registration. Group created with '$' offset — no historical replay on first connect. Closes NCS-101 https://knockoutwhist.youtrack.cloud/issue/NCS-101
This commit is contained in:
@@ -36,7 +36,6 @@ class EventPublisher:
|
||||
new XAddArgs().maxlen(maxStreamLen).nearlyExactTrimming(),
|
||||
Map("data" -> json).asJava,
|
||||
)
|
||||
redis.pubsub(classOf[String]).publish(s"${redisConfig.prefix}:bot:$botId:events", json)
|
||||
()
|
||||
|
||||
def publishChallengeCreated(destUserId: String, challengeId: String, challengerName: String): Unit =
|
||||
|
||||
Reference in New Issue
Block a user