powered by Jive Software

Group Chat NullPointerException

I am building a branded client that is locked down to a specific server. I understand that process and have no issues with that part. When the client is connected to my server, everything works fine; however, when I connect to another server (which I have no control over), the group chat will not list the participants. Below is the error that I get. When I download the pre-compiled version of Spark, it works perfectly, albeit, not locked down. I have since compiled the main trunk with the only modifications being to allow Ant 1.9 and point izpack and launch4j to their proper locations. It had the same results. Everything works, it just will not list the participants in group chat.

Exception in thread “AWT-EventQueue-0” java.lang.NullPointerException

at java.util.concurrent.ConcurrentHashMap.hash(Unknown Source)

at java.util.concurrent.ConcurrentHashMap.get(Unknown Source)

at org.jivesoftware.smack.Roster.getPresence(Roster.java:469)

at org.jivesoftware.spark.PresenceManager.getPresence(PresenceManager.java:117)

at org.jivesoftware.spark.ui.conferences.GroupChatParticipantList.addParticipant(G roupChatParticipantList.java:376)

at org.jivesoftware.spark.ui.conferences.GroupChatParticipantList$3$1.run(GroupCha tParticipantList.java:220)

at java.awt.event.InvocationEvent.dispatch(Unknown Source)

at java.awt.EventQueue.dispatchEventImpl(Unknown Source)

at java.awt.EventQueue.access$200(Unknown Source)

at java.awt.EventQueue$3.run(Unknown Source)

at java.awt.EventQueue$3.run(Unknown Source)

at java.security.AccessController.doPrivileged(Native Method)

at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source)

at java.awt.EventQueue.dispatchEvent(Unknown Source)

at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)

at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)

at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)

at java.awt.EventDispatchThread.pumpEvents(Unknown Source)

at java.awt.EventDispatchThread.pumpEvents(Unknown Source)

at java.awt.EventDispatchThread.run(Unknown Source)

After putting some logging in place, this is what I am seeing (including where I put the logging and what the loggin step was):

java.org.jivesoftware.spark.PresenceManager.getJidFromMUCPresence

Log.warning("getJidFromMUCPresence: getStatus - " + presence.getStatus() + " - getMode = " + presence.getMode());
Aug 12, 2013 9:00:28 AM org.jivesoftware.spark.util.log.Log warning
WARNING: getJidFromMUCPresence: getStatus - null - getMode = null

java.org.jivesoftware.spark.PresenceManager.getJidFromMUCPresence
Log.warning("getJidFromMUCPresence for: fullJid - " + fullJid + " - userJid = " + userJid);
Aug 12, 2013 9:00:28 AM org.jivesoftware.spark.util.log.Log warning
WARNING: getJidFromMUCPresence for: fullJid - null - userJid = null

java.org.jivesoftware.spark.PresenceManager.processPacket
Log.warning("processPacket: userid - " + userid + " - jid = " + jid);
Aug 12, 2013 9:00:28 AM org.jivesoftware.spark.util.log.Log warning
WARNING: processPacket: userid - xxxx@xxxxxxx.com/John F - DAL MGR - jid = null

java.org.jivesoftware.spark.ui.conferences.GroupChatParticipantList.addParticip ant
Log.warning("addParticipant(input): participantJID - " + participantJID + " - userJID = " + userJID + " - presence.getStatus - " + presence.getStatus() + " - presence.getMode = " + presence.getMode());
Aug 12, 2013 9:00:28 AM org.jivesoftware.spark.util.log.Log warning
WARNING: addParticipant(input): participantJID - xxxx@xxxxxxx.com.com/John F - DAL MGR - userJID = null - presence.getStatus - null - presence.getMode = null

java.org.jivesoftware.spark.ui.conferences.GroupChatParticipantList.addParticip ant
Log.warning("addParticipant(if/else): userJID - " + userJID + " - participantJID = " + participantJID + " - nickname = " + nickname + " - affiliation - " + affiliation + " - userRole - " + userRole);
Aug 12, 2013 9:00:28 AM org.jivesoftware.spark.util.log.Log warning
WARNING: addParticipant(if/else): userJID - null - participantJID = xxxx@xxxxxxx.com.com/John F - DAL MGR - nickname = John F - DAL MGR - affiliation - member - userRole - participant

java.org.jivesoftware.spark.PresenceManager.getPresence
Log.warning("getPresence: userJID - " + jid);
Aug 12, 2013 9:00:28 AM org.jivesoftware.spark.util.log.Log warning
WARNING: getPresence: userJID - null

This happens for every person that is in the group chat list (after each person it produces the above nullpointerexception. Is there some type of user permission that would make it work in the pre-compiled spark client, but not in the downloaded version? Or is there something else that I am missing?