Cannot read SLD file from behind an apache webserver

Description

I've encountered something strange.

We have a webapplication in which we use a wms layer from geoserver (2.14.0). In that webapplication we create a filter (spatial and/or attribute) from which we create a SLD. We put a URL to that SLD in the getmap request.

When the sld is located on an external server, everything is fine, but when it's on the same server we get the error message in the responseimage "Error while getting SLD. See the log for details". The logs are [1].
When inspecting SLDHandler on 140, it seemed that the method getVersionAndReader(input) returned a null, probably because of [2]. So I've commented out that check, recompiled and put the new .class files into the war and deployed it, and then it worked.

The network setup is as follows:

internet <--> apache on server 1 <---> apache on server 2 <---> tomcat (with geoserver in it) on server 2

Traffic from server 2 to server 2, is a direct connection (not routed via server 1).
When the sld resides on the internet, everything is fine.
When the sld resides on server 2, and routed via apache, we get the error.
When the sld resides on server 2, but accessed directly via the tomcat http connector, it works.

Our conclusion was that the apache on server 2 does something weird.

[2] https://github.com/geoserver/geoserver/blob/2.14.0/src/main/src/main/java/org/geoserver/catalog/SLDHandler.java#L325-L327
[1]

Environment

None

Status

Assignee

Unassigned

Reporter

Meine Toonen

Triage

Fix versions

Affects versions

Priority

Medium
Configure