Parcourir la source

Use bounded channel for streaming (#6625)

BrennanConroy il y a 7 ans
Parent
commit
17616a5dba
1 fichiers modifiés avec 3 ajouts et 1 suppressions
  1. 3 1
      src/SignalR/server/Core/src/StreamTracker.cs

+ 3 - 1
src/SignalR/server/Core/src/StreamTracker.cs

@@ -78,7 +78,9 @@ namespace Microsoft.AspNetCore.SignalR
 
             public ChannelConverter()
             {
-                _channel = Channel.CreateUnbounded<T>();
+                // TODO: Make this configurable or figure out a good limit
+                // https://github.com/aspnet/AspNetCore/issues/4399
+                _channel = Channel.CreateBounded<T>(10);
             }
 
             public Type GetItemType()