Quantcast
Channel: Ignite Realtime: Message List
Viewing all articles
Browse latest Browse all 11412

Re: NullPointerException in EntityCapsManager in 4.1.0-rc3

$
0
0

Although this is interesting discussion about threading, I have the feeling I did not explained correctly, as what I see as the cause of the problem I mentioned.

 

The CapsEntitiyManager is setup as a lazy initializing manager. This has the effect that even the static code which attaches the manager as a connectionCreationListerner is only then executed when the Class is loaded, on the first time the class is used in the code. In my case this happens a significant time after the login. So I don't think it is solution to call the listeners somewhere in the constructor of the XMPPConnection, as on this moment, the CapsEntitiyManager class is not yet loaded, and therefore has not yet registered itself as a listener.

 

I think the only correct solution is, is to make sure that each manager should properly initialize itself, meaning in this case calling the processCapsStreamFeatureIfAvailable(connection); somewhere in the constructor.


Viewing all articles
Browse latest Browse all 11412

Trending Articles