mkurz commented on code in PR #1114:
URL: https://github.com/apache/pekko-http/pull/1114#discussion_r3639423811


##########
http-core/src/main/scala/org/apache/pekko/http/impl/engine/ws/Handshake.scala:
##########
@@ -122,26 +123,47 @@ private[http] object Handshake {
             case OptionVal.Some(p) => p.protocols
             case _                 => Nil
           }
+          val clientRequestedExtensions = headers.collect {
+            case extensions: `Sec-WebSocket-Extensions` => 
extensions.extensions
+          }.flatten
+          val perMessageDeflate =
+            PerMessageDeflate.negotiate(
+              clientRequestedExtensions,
+              settings.asInstanceOf[WebSocketSettingsImpl].compression)

Review Comment:
   Addressed by #1173: the handshake now pattern-matches 
`WebSocketSettingsImpl`. Unknown custom implementations skip compression 
negotiation instead of causing a `ClassCastException`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to