I have a raster with 95 different integer values (1-95). When I do a GetFeatureInfo request, GeoServer sends back the raster cell integer value. That makes sense, but what if I want a text value (a descriptive label). I have the descriptive label in my style (.sld) and the legend is generated using this label. I'd like to get that label back through GetFeatureInfo. ArcGIS Server solves this problem by associating an attribute table to the raster (a row for each unique raster value). Is there a way to accomplish this sort of thing in GeoServer/WMS?
Recent Geoserver versions
It is now possible to include the labels in the response, eventually along with the values, using a vendor option, see the documentation for details:
Before GeoServer 2.18.3, 2.19.1, and 2.20
Generally speaking, no, there is no such way. However, if your particular output format is HTML, then you can write your own freemarker template and put the value to label mapping logic in there: http://docs.geoserver.org/stable/en/user/tutorials/GetFeatureInfo/index.html#tutorials-getfeatureinfo
Adding the same functionality as ArcGIS would be a new feature, you can read how to handle feature requests here: https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer