Refactor: split eventBus and signalRHub god objects into cohesive collaborators - #7
Merged
Merged
Conversation
…laborators eventBus drops from 25 to 14 methods: it is now a pure orchestrator owning the subscription broker and interval scheduler, delegating message rendering, recipient partitioning, delayed-emission cancellation and push side effects to a new messageDelivery type. The delivery engine owns the MessageRenderer/ConsumerBus contracts and the push observer; the bus owns event firing, registration, scheduling and shutdown. signalRHub drops from ~25 to 15 methods: it keeps the HTTP transport (negotiate/upgrade), protocol framing and document model, while all connection, token and open-stream state plus payload delivery moves to a new signalRConnRegistry. The registry owns the hub mutex, so transport handling no longer reaches into connection state directly. The unused signalRConnection.server back-pointer is dropped. Behavior preserved: full suite green, lint clean, 100% scenario coverage, 82.6% statement coverage. Tests updated to drive the new registry/delivery surfaces instead of reaching into hub.conns / hub.mu.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
eventBus drops from 25 to 14 methods: it is now a pure orchestrator owning the subscription broker and interval scheduler, delegating message rendering, recipient partitioning, delayed-emission cancellation and push side effects to a new messageDelivery type. The delivery engine owns the MessageRenderer/ConsumerBus contracts and the push observer; the bus owns event firing, registration, scheduling and shutdown.
signalRHub drops from ~25 to 15 methods: it keeps the HTTP transport (negotiate/upgrade), protocol framing and document model, while all connection, token and open-stream state plus payload delivery moves to a new signalRConnRegistry. The registry owns the hub mutex, so transport handling no longer reaches into connection state directly. The unused signalRConnection.server back-pointer is dropped.
Behavior preserved: full suite green, lint clean, 100% scenario coverage, 82.6% statement coverage. Tests updated to drive the new registry/delivery surfaces instead of reaching into hub.conns / hub.mu.