NIFI-3561: Fix WS port forwarding

Fixed service instance lookup to use local port so that it works when
it is accessed through port forwarding.

This fixes: #1568

Signed-off-by: Andre F de Miranda <trixpan@users.noreply.github.com>
This commit is contained in:
Koji Kawamura 2017-03-07 17:08:47 +09:00 committed by Andre F de Miranda
parent 776a00b0be
commit 7c19796eb2
1 changed files with 1 additions and 1 deletions

View File

@ -127,7 +127,7 @@ public class JettyWebSocketServer extends AbstractJettyWebSocketService implemen
@Override
public Object createWebSocket(ServletUpgradeRequest servletUpgradeRequest, ServletUpgradeResponse servletUpgradeResponse) {
final URI requestURI = servletUpgradeRequest.getRequestURI();
final int port = requestURI.getPort();
final int port = servletUpgradeRequest.getLocalPort();
final JettyWebSocketServer service = portToControllerService.get(port);
if (service == null) {