[
https://issues.apache.org/jira/browse/FLINK-7738?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16191393#comment-16191393
]
ASF GitHub Bot commented on FLINK-7738:
---------------------------------------
Github user EronWright commented on a diff in the pull request:
https://github.com/apache/flink/pull/4767#discussion_r142696121
--- Diff:
flink-runtime/src/main/java/org/apache/flink/runtime/rest/handler/AbstractRestHandler.java
---
@@ -157,7 +160,12 @@ protected void respondAsLeader(final
ChannelHandlerContext ctx, Routed routed, T
HandlerUtils.sendErrorResponse(ctx, httpRequest, new
ErrorResponseBody("Internal server error."),
HttpResponseStatus.INTERNAL_SERVER_ERROR);
}
} else {
- HandlerUtils.sendResponse(ctx,
httpRequest, resp, messageHeaders.getResponseStatusCode());
+ if (resp instanceof
WebSocketUpgradeResponseBody) {
+ upgradeToWebSocket(ctx, routed,
(WebSocketUpgradeResponseBody) resp);
--- End diff --
The REST handler is not active after the upgrade is complete, and it would
be harmless to remove from the pipeline. The message handler takes over,
reading and writing websocket frames based on typed messages.
> Create WebSocket handler (server)
> ---------------------------------
>
> Key: FLINK-7738
> URL: https://issues.apache.org/jira/browse/FLINK-7738
> Project: Flink
> Issue Type: Sub-task
> Components: Cluster Management, Mesos
> Reporter: Eron Wright
> Assignee: Eron Wright
>
> An abstract handler is needed to support websocket communication.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)