Handled exception when processing annotations

Fixes GLASSFISH-21265 and passes Spring Boot deployment test