discourse-ai/app/controllers/discourse_ai
Sam cf220c530c
FIX: Improve MessageBus efficiency and correctly stop streaming (#1362)
* FIX: Improve MessageBus efficiency and correctly stop streaming

This commit enhances the message bus implementation for AI helper streaming by:

- Adding client_id targeting for message bus publications to ensure only the requesting client receives streaming updates
- Limiting MessageBus backlog size (2) and age (60 seconds) to prevent Redis bloat
- Replacing clearTimeout with Ember's cancel method for proper runloop management, we were leaking a stop
- Adding tests for client-specific message delivery

These changes improve memory usage and make streaming more reliable by ensuring messages are properly directed to the requesting client.

* composer suggestion needed a fix as well.

* backlog size of 2 is risky here cause same channel name is reused between clients
2025-05-23 16:23:06 +10:00
..
admin FEATURE: Examples support for personas. (#1334) 2025-05-13 10:06:16 -03:00
ai_bot FEATURE: allow passing in data attributes to an artifact (#1346) 2025-05-19 15:44:37 +10:00
ai_helper FIX: Improve MessageBus efficiency and correctly stop streaming (#1362) 2025-05-23 16:23:06 +10:00
discord FEATURE: Discord Bot integration (#831) 2024-10-16 12:41:18 -03:00
embeddings FIX: Invalid access error should be populated to user (#1303) 2025-04-30 12:10:10 -07:00
sentiment FIX: Ensure category badging present in sentiment reports (#1222) 2025-03-26 12:37:41 -07:00
summarization FIX/REFACTOR: FoldContent revamp (#866) 2024-10-25 11:51:17 -03:00