users@hk2.java.net

Events throwing Nullpointer Exception

From: buko <buko_at_chiubarobot.com>
Date: Fri, 9 May 2014 08:36:24 -0400

Took a stab at using Hk2 Events in 2.3.0-b4 and b5. Result is a NPE:

Exception in thread "main" java.lang.NullPointerException at
org.glassfish.hk2.internal.DefaultTopicDistributionService.handleDescriptorToClass(DefaultTopicDistributionService.java:165)
at
org.glassfish.hk2.internal.DefaultTopicDistributionService.distributeMessage(DefaultTopicDistributionService.java:229)
at org.jvnet.hk2.internal.TopicImpl.publish(TopicImpl.java:82)

In line 165 there is no guard against the fact that the class2method map
can return null. Has this been tested?