-
Notifications
You must be signed in to change notification settings - Fork 628
Remove ShardMessenger and clean up ShardRunner
#3120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Conversation
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
9a6c404 to
75013c9
Compare
75013c9 to
3f95d9a
Compare
09f86bd to
594fb50
Compare
99f3c46 to
ba52513
Compare
Inlines `ShardMessenger` fields/methods into `Context` and removes unnecessary `ShardRunnerMessage` variants, namely `Restart`, `Close`, and `Message`.
Since each `ShardRunner` create a `Context` specific to it, and already holds a channel back to the manager, we can use to expose latency information for the corresponding shard, and also facilitate shutdown requests back to the manager.
ba52513 to
bff95f6
Compare
jamesbt365
approved these changes
Mar 14, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
arqunis
approved these changes
Mar 14, 2025
GnomedDev
pushed a commit
to GnomedDev/serenity
that referenced
this pull request
Mar 26, 2025
Follow up to serenity-rs#3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
GnomedDev
pushed a commit
to GnomedDev/serenity
that referenced
this pull request
Mar 26, 2025
Follow up to serenity-rs#3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
arqunis
pushed a commit
that referenced
this pull request
Apr 5, 2025
GnomedDev
pushed a commit
that referenced
this pull request
Apr 28, 2025
Follow up to #3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
GnomedDev
pushed a commit
that referenced
this pull request
Apr 28, 2025
GnomedDev
pushed a commit
that referenced
this pull request
May 19, 2025
Follow up to #3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
GnomedDev
pushed a commit
that referenced
this pull request
May 19, 2025
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Jun 30, 2025
Follow up to serenity-rs#3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Jun 30, 2025
The changes in serenity-rs#3120 now let us remove the clause due to changes in ownership requirements.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Jun 30, 2025
Follow up to serenity-rs#3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Jun 30, 2025
The changes in serenity-rs#3120 now let us remove the clause due to changes in ownership requirements.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Jun 30, 2025
Follow up to serenity-rs#3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Jun 30, 2025
The changes in serenity-rs#3120 now let us remove the clause due to changes in ownership requirements.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Jul 28, 2025
Follow up to serenity-rs#3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Jul 28, 2025
The changes in serenity-rs#3120 now let us remove the clause due to changes in ownership requirements.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Jul 28, 2025
Follow up to serenity-rs#3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Jul 28, 2025
The changes in serenity-rs#3120 now let us remove the clause due to changes in ownership requirements.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Oct 7, 2025
Follow up to serenity-rs#3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Oct 7, 2025
The changes in serenity-rs#3120 now let us remove the clause due to changes in ownership requirements.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Oct 7, 2025
Follow up to serenity-rs#3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Oct 7, 2025
The changes in serenity-rs#3120 now let us remove the clause due to changes in ownership requirements.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Oct 7, 2025
Follow up to serenity-rs#3108. Inlines the fields and methods of `ShardMessenger` into `Context` and changes collectors to take `&Context`. Also, removes the `ShardRunnerMessage::{Close, Message}` variants, adds an `UpdateVoiceState` variant (Songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the `ShardRunner` code.
mkrasnitski
added a commit
to mkrasnitski/serenity
that referenced
this pull request
Oct 7, 2025
The changes in serenity-rs#3120 now let us remove the clause due to changes in ownership requirements.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
breaking change
The public API is changed, resulting in miscompilations or unexpected new behaviour for users
collector
Related to the `collector` module.
enhancement
An improvement to Serenity.
examples
Related to Serenity's examples.
gateway
Related to the `gateway` module.
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.
Follow up to #3108.
Inlines the fields and methods of
ShardMessengerintoContextand changes collectors to take&Context. Also, removes theShardRunnerMessage::{Close, Message}variants, adds anUpdateVoiceStatevariant (songbird will want to use this) and combines the 3 presence-related variants into one. Plus some miscellaneous cleanup of the ShardRunner code.