Skip to content

Conversation

@mayuki
Copy link
Member

@mayuki mayuki commented May 1, 2025

No description provided.

@mayuki mayuki requested a review from Copilot May 1, 2025 02:23
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR fixes an issue that prevented reusing group names with Redis and NATS backplanes by ensuring that disposed groups are properly removed from the internal dictionaries. Key changes include:

  • Adding tests (for in-memory, Redis, and NATS) to verify that groups can be recreated after disposal.
  • Updating the provider classes to pass a removal callback to group implementations.
  • Modifying group classes (RedisGroup and NatsGroup) to invoke a disposal callback to remove disposed groups.

Reviewed Changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
test/Multicaster.Tests/InMemoryGroupTest.cs Added a test to verify group reuse after disposal in the in-memory provider.
test/Multicaster.Distributed.Redis.Tests/RedisGroupTest.cs Updated tests to use the helper CreateJsonSerializedInvocation for assertions.
test/Multicaster.Distributed.Nats.Tests/NatsGroupTest.cs Added a test to verify group reuse after disposal with the NATS provider.
src/Multicaster.Distributed.Redis/RedisGroupProvider.cs Updated group creation methods to pass a removal callback that cleans up disposed groups.
src/Multicaster.Distributed.Redis/RedisGroup.cs Modified Dispose to call the removal callback for group cleanup.
src/Multicaster.Distributed.Nats/NatsGroupProvider.cs Updated group creation methods to pass a removal callback to NatsGroup.
src/Multicaster.Distributed.Nats/NatsGroup.cs Modified Dispose to call the removal callback for group cleanup.

@mayuki mayuki merged commit 7f45cf6 into main May 1, 2025
2 checks passed
@mayuki mayuki deleted the feature/FixReuseGroupName branch May 1, 2025 02:39
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.

2 participants