I have a custom annotation in my main project using play framework v1.5, that's not coming from an external dependency (jar). Using this annotation on a non-indexed class results in a NPE while building the SessionFactory:
java.lang.NullPointerException at org.hibernate.search.util.impl.ReflectionHelper.isSearchAnnotation(ReflectionHelper.java:181)
Looking at the code in the debugger shows, that annotation.annotationType().getPackage() returns null for my custom annotation (at this time). A behavior that's documented in the getPackage() method, so it's valid, although I can't reproduce it with a stand-alone test-case w/out using the play-framework with all its classloading magic
Nonetheless I think a null-check should be added in ReflectionHelper#isSearchAnnotation(...) to avoid this.