-
-
Notifications
You must be signed in to change notification settings - Fork 799
Closed
Labels
🔍 investigateIndicates that an issue or pull request needs more information.Indicates that an issue or pull request needs more information.
Milestone
Description
Describe the bug
v10.4.3
Using subscriptions via the InMemorySubscriptionProvider, calling SubscribeAsync after callling CompleteAsync on a topic with the same key throws the following exception:
The semaphore has been disposed.
at System.Threading.SemaphoreSlim.CheckDispose() at System.Threading.SemaphoreSlim.WaitAsync(Int32 millisecondsTimeout, CancellationToken cancellationToken) at System.Threading.SemaphoreSlim.WaitAsync() at HotChocolate.Subscriptions.InMemory.EventTopic`1.SubscribeAsync(CancellationToken cancellationToken) at HotChocolate.Subscriptions.InMemory.InMemoryPubSub.SubscribeAsync[TTopic,TMessage](TTopic topic, CancellationToken cancellationToken)
To Reproduce
Steps to reproduce the behavior:
- Create a new InMemorySubscription using
ITopicEventReceiver.SubscribeAsync - Complete that subscription using
ITopicEventSender.CompleteAsyncusing the same key as above. - Try to create another subscription, using the same key and method as step 1.
- Exception thrown
Expected behavior
Can seamlessly create a new subscription using previously completed key.
Desktop (please complete the following information):
- OS: Windows 10
Metadata
Metadata
Assignees
Labels
🔍 investigateIndicates that an issue or pull request needs more information.Indicates that an issue or pull request needs more information.