NullPointerException running shinyproxy behind apache2 with mod proxy

When I try to run Shinyproxy behind a apache2 proxy, i always get the following error:

2018-08-15 21:19:48.699 ERROR 29031 --- [   XNIO-2 I/O-3] io.undertow.request                      : UT005071: Undertow request failed HttpServerExchange{ GET /endpoint/1eb188b5-babd-4908-aef4-e78a464d6880/ request {Accept=[text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8], Accept-Language=[en-US,en;q=0.5], Accept-Encoding=[gzip, deflate, br], X-Forwarded-Server=[***], User-Agent=[Mozilla/5.0 (X11; Linux x86_64; rv:61.0) Gecko/20100101 Firefox/61.0], Connection=[Keep-Alive], X-Forwarded-Proto=[https], X-Forwarded-For=[128.176.86.4], Cookie=[_xsrf=2|7309ab1f|44eee888b65d8cafcf92fd00af79ce9c|1533463228; username-localhost-8889="2|1:0|10:1533808705|23:username-localhost-8889|44:ODRiYjNiNjk3YjI4NGIyMGE5NjYxNzgyOGVjMTNlN2U=|d30e71f7a1e8ab9966f7bb22b524d03a629afa57e77193532187cbaaf25c9e2b"], Referer=[https://localhost/app/01_***], Upgrade-Insecure-Requests=[1], Host=[localhost], X-Forwarded-Host=[localhost]} response HttpServerExchange{ GET /endpoint/1eb188b5-babd-4908-aef4-e78a464d6880/ request {Accept=[text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8], Accept-Language=[en-US,en;q=0.5], Accept-Encoding=[gzip, deflate, br], X-Forwarded-Server=[***], User-Agent=[Mozilla/5.0 (X11; Linux x86_64; rv:61.0) Gecko/20100101 Firefox/61.0], Connection=[Keep-Alive], X-Forwarded-Proto=[https], X-Forwarded-For=[128.176.86.4], Cookie=[_xsrf=2|7309ab1f|44eee888b65d8cafcf92fd00af79ce9c|1533463228; username-localhost-8889="2|1:0|10:1533808705|23:username-localhost-8889|44:ODRiYjNiNjk3YjI4NGIyMGE5NjYxNzgyOGVjMTNlN2U=|d30e71f7a1e8ab9966f7bb22b524d03a629afa57e77193532187cbaaf25c9e2b"], Referer=[https://localhost/app/01_***], Upgrade-Insecure-Requests=[1], Host=[localhost], X-Forwarded-Host=[localhost]} response {}}}

java.lang.NullPointerException: null
	at eu.openanalytics.containerproxy.util.ProxyMappingManager$MappingOwnerInfo.isSame(ProxyMappingManager.java:125) ~[containerproxy-0.2.1-SNAPSHOT.jar!/:0.2.1-SNAPSHOT]
	at eu.openanalytics.containerproxy.util.ProxyMappingManager.requestHasAccess(ProxyMappingManager.java:94) ~[containerproxy-0.2.1-SNAPSHOT.jar!/:0.2.1-SNAPSHOT]
	at eu.openanalytics.containerproxy.ContainerProxyApplication$ProtectedPathHandler.handleRequest(ContainerProxyApplication.java:100) ~[containerproxy-0.2.1-SNAPSHOT.jar!/:0.2.1-SNAPSHOT]
	at io.undertow.server.handlers.HttpContinueReadHandler.handleRequest(HttpContinueReadHandler.java:65) ~[undertow-core-1.4.22.Final.jar!/:1.4.22.Final]
	at io.undertow.server.Connectors.executeRootHandler(Connectors.java:336) ~[undertow-core-1.4.22.Final.jar!/:1.4.22.Final]
	at io.undertow.server.protocol.http.HttpReadListener.handleEventWithNoRunningRequest(HttpReadListener.java:255) [undertow-core-1.4.22.Final.jar!/:1.4.22.Final]
	at io.undertow.server.protocol.http.HttpReadListener.handleEvent(HttpReadListener.java:136) [undertow-core-1.4.22.Final.jar!/:1.4.22.Final]
	at io.undertow.server.protocol.http.HttpReadListener.handleEvent(HttpReadListener.java:59) [undertow-core-1.4.22.Final.jar!/:1.4.22.Final]
	at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92) [xnio-api-3.3.8.Final.jar!/:3.3.8.Final]
	at org.xnio.conduits.ReadReadyHandler$ChannelListenerHandler.readReady(ReadReadyHandler.java:66) [xnio-api-3.3.8.Final.jar!/:3.3.8.Final]
	at org.xnio.nio.NioSocketConduit.handleReady(NioSocketConduit.java:88) [xnio-nio-3.3.8.Final.jar!/:3.3.8.Final]
	at org.xnio.nio.WorkerThread.run(WorkerThread.java:561) [xnio-nio-3.3.8.Final.jar!/:3.3.8.Final]

My apache config is the following:

RequestHeader set X-Forwarded-Proto https
ProxyPreserveHost On

# Maps remote servers into the local server URL-space using regex
ProxyPassMatch          "^/(.+)/websocket"      "wss://localhost:8080/$1/websocket" keepalive=On

# Maps remote servers into the local server URL-space
ProxyPass               /      http://localhost:8080/

# Adjust the URL in HTTP response headers sent from reverse proxied server
ProxyPassReverse        /      http://localhost:8080/

ProxyRequests Off

Sometimes when I access the site as first user, the application loads as expected. But when I try to access the same app with a second tab or computer, the above error is raised.

Thank you for any help in advance
Jan

Hi @jernsting,

Are you using authentication: none ? The error stack makes me suspect it is this issue: