Reflection hack for Tomcat 8 API change

Fixes gh-1148