Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Geo viewer sidebar is not populated when GeoServer responds with an exception #2141

Open
thatbudakguy opened this issue Apr 22, 2024 · 0 comments

Comments

@thatbudakguy
Copy link
Member

This might be specific to our testing setup, but tests that assert that the geo viewer sidebar can be opened to view feature information appear to be intermittently failing as of 577f2e4. Some earlier CI failures like https://github.com/sul-dlss/sul-embed/actions/runs/8602436918/job/23572000525 may be related.

The problem looks like the geo viewer javascript where we make the WMS request to GeoServer to get the feature info and insert it into the sidebar. Specifically, if GeoServer responds with a 200 but the data is an exception encoded as JSON, we bail out:

success: function(data) {
// Handle the case where GeoServer returns a 200 but with an exception;
if (data.exceptions && data.exceptions.length > 0) {
return;
}

In my testing locally, I could trigger this codepath about 50% of the time, with no way of predicting whether or not it would happen. For whatever reason, GeoServer sometimes responds to the GetFeatureInfo request with an exception indicating it couldn't find this layer. I tried adding a retry method with backoff, but couldn't see it helping.

GeoServer's access logs on the server show it responding to each request, but don't give any hint as to what might be going wrong:

172.20.21.194 - - [22/Apr/2024:13:56:48 -0700] "GET /geoserver/wms/?LAYERS=druid%3Acz128vq0535&BBOX=25.7080078125%2C-3.3050503438610943%2C38.86962890625001%2C6.064086258846952&WIDTH=1198&HEIGHT=854&QUERY_LAYERS=druid%3Acz128vq0535&X=599&Y=427&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetFeatureInfo&STYLES=&SRS=EPSG%3A4326&EXCEPTIONS=application%2Fjson&INFO_FORMAT=application%2Fjson HTTP/1.1" 200 136 "http://127.0.0.1:63208/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) HeadlessChrome/123.0.0.0 Safari/537.36"

The only potentially relevant thing I found online about this claims the issue was corrupted files in GeoServer's security directory: https://gis.stackexchange.com/questions/20726/intermittent-could-not-find-layer-and-bad-request-errors-on-geoserver

thatbudakguy added a commit that referenced this issue Apr 22, 2024
This marks a geo viewer spec that was intermittently failing as
pending while the underlying issue can be investigated.

See #2141
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant