ReplaySubject.Unsubscribe is very slow
Open
[area] Rx
- Dominant language
- C#
- Stars
- 7.2k
- Forks
- 798
- PR merge metrics
- No merged PRs in 30d
Description
ReplaySubject makes usage of ImmutableList to maintain a list of subscribers.
When calling ReplaySubject.Unsubscribe we will call ImmutableList.Remove, which is inefficient for various reasons.
It might be more efficient use a collection which uses GetHashCode.
Additionally, it should be noted, that most accesses to the ImmutableList uses lock(_gate). It might be possible to use a mutable list/hashset instead.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.