Skip to content

feat(websocket): add Redis Pub/Sub for cross-instance delivery - #2336

Merged
github-actions[bot] merged 12 commits into
Smartdevs17:mainfrom
OnlyBarry:fix/2209-redis-websocket-pubsub
Nov 27, 2026
Merged

github-actions[bot] merged 12 commits into
Smartdevs17:mainfrom
OnlyBarry:fix/2209-redis-websocket-pubsub

Conversation

@OnlyBarry

Copy link
Copy Markdown
Contributor

Summary

  • Add an ioredis-backed Pub/Sub adapter with dedicated publisher and subscriber connections.
  • Reuse the repository's Redis environment configuration and verify both connections before returning the adapter.
  • Make WebSocket server startup wait for subscription readiness and close the adapter during graceful shutdown.
  • Add adapter lifecycle and multi-instance fan-out tests.
  • Document production setup, Redis Pub/Sub delivery semantics, and local replay limitations.

Testing

  • Added unit tests for publishing, channel subscription fan-out, handler isolation, connection cleanup, and post-shutdown behavior.
  • Added a multi-instance WebSocket delivery test using a shared Pub/Sub test adapter.

Automated test execution was not available in this session; CI should run the backend test suite.

Closes #2209

@github-actions
github-actions Bot merged commit fa27a08 into Smartdevs17:main Nov 27, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Refactor WebSocket subscription server for pub/sub scale

1 participant