You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: ModuleFast.psm1
+5-4Lines changed: 5 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -244,11 +244,12 @@ function New-ModuleFastClient {
244
244
Write-Debug'Creating new ModuleFast HTTP Client. This should only happen once!'
245
245
$ErrorActionPreference='Stop'
246
246
#SocketsHttpHandler is the modern .NET 5+ default handler for HttpClient.
247
-
#We want more concurrent connections to improve our performance and fairly aggressive timeouts
248
-
#The max connections are only in case we end up using HTTP/1.1 instead of HTTP/2 for whatever reason.
247
+
249
248
$httpHandler= [SocketsHttpHandler]@{
249
+
#The max connections are only in case we end up using HTTP/1.1 instead of HTTP/2 for whatever reason. HTTP/2 will only use one connection (but multiple streams) per the spec unless EnableMultipleHttp2Connections is specified
250
250
MaxConnectionsPerServer=10
251
-
EnableMultipleHttp2Connections=$true
251
+
#Reduce the amount of round trip confirmations by setting window size to 64MB. ModuleFast should primarily be used on reliable fast connections. Dynamic scaling will reduce this if needed.
252
+
InitialHttp2StreamWindowSize=65535000
252
253
AutomaticDecompression='All'
253
254
}
254
255
@@ -659,7 +660,7 @@ function Install-ModuleFastHelper {
659
660
Write-Verbose"${module}: Existing module found at $installPath and its version $existingVersion is the same as the requested version. -Update was specified so we are assuming that the discovered online version is the same as the local version and skipping this module."
660
661
continue
661
662
} else {
662
-
throw [System.NotImplementedException]"${module}: Existing module found at $installPath and its version $existingVersion is the same as the requested version. This is probably a bug because it should have been detected by localmodule detection. Use -Update to override..."
663
+
throw [NotImplementedException]"${module}: Existing module found at $installPath and its version $existingVersion is the same as the requested version. This is probably a bug because it should have been detected by localmodule detection. Use -Update to override..."
0 commit comments