I would like to report an unexpected behavior we have been experiencing while doing some GetFeatureInfo requests to Geoserver. The issue is that while the standard does not say anything about the requirement of including the LAYERS parameter in the requests, it seems that Geoserver needs it to respond appropriately.
As I mention above, the standard only lists the QUERY_LAYERS parameter to specify what layers are going to be queried (see picture attached). However, an error occurs if a request like the following is sent:
http://[GEOSERVER_ROOT_URL]/wms?bbox=-130,24,-66,50&styles=population&format=jpeg&info_format=text/plain&request=GetFeatureInfo&query_layers=topp:states&width=550&height=250&x=170&y=160
Instead, if the LAYERS parameter is added, it works as it should:
http://[GEOSERVER_ROOT_URL]/wms?bbox=-130,24,-66,50&styles=population&format=jpeg&info_format=text/plain&request=GetFeatureInfo&layers=topp:states&query_layers=topp:states&width=550&height=250&x=170&y=160
Is there any explanation to justify that Geoserver needs an additional parameter compared to what the standard says?
Best regards.
|