@@ -188,7 +188,10 @@ public struct HTTP1WebSocketUpgradeChannel: ServerChildChannel, HTTPChannelHandl
188188 } ,
189189 upgradePipelineHandler: { channel, handler in
190190 channel. eventLoop. makeCompletedFuture {
191- let asyncChannel = try NIOAsyncChannel < WebSocketFrame , WebSocketFrame > ( wrappingChannelSynchronously: channel)
191+ let asyncChannel = try NIOAsyncChannel < WebSocketFrame , WebSocketFrame > (
192+ wrappingChannelSynchronously: channel,
193+ configuration: . init( isOutboundHalfClosureEnabled: true )
194+ )
192195 return UpgradeResult . websocket ( asyncChannel, handler, logger)
193196 }
194197 }
@@ -201,7 +204,10 @@ public struct HTTP1WebSocketUpgradeChannel: ServerChildChannel, HTTPChannelHandl
201204 [ HTTP1ToHTTPServerCodec ( secure: false ) ] + self . additionalChannelHandlers ( ) + [ HTTPUserEventHandler ( logger: logger) ]
202205 return channel. eventLoop. makeCompletedFuture {
203206 try channel. pipeline. syncOperations. addHandlers ( childChannelHandlers)
204- let asyncChannel = try NIOAsyncChannel < HTTPRequestPart , HTTPResponsePart > ( wrappingChannelSynchronously: channel)
207+ let asyncChannel = try NIOAsyncChannel < HTTPRequestPart , HTTPResponsePart > (
208+ wrappingChannelSynchronously: channel,
209+ configuration: . init( isOutboundHalfClosureEnabled: true )
210+ )
205211 if upgradeAttempted. value {
206212 return UpgradeResult . failedUpgrade ( asyncChannel, logger)
207213 } else {
0 commit comments