Install a fresh Openfire, enable hazelcast clustering.
Login to Openfire, navigate to the "Clustering" page. Select "Disabled", and click "Save Settings".
Expected results
The Clustering page indicates that clustering is disabled.
Actual results
The browser shows a NullPointerException from Openfire. The server stops responding. It is necessary to stop and restart Openfire, at which point the Clustering page indicates that clustering is disabled.
Exception:
java.lang.NullPointerException
at org.jivesoftware.openfire.admin.decorators.main_jsp._jspService(main_jsp.java:162)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:812)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:587)
Environment
None
Activity
Greg Thomas
March 1, 2018 at 4:33 PM
NB. Fixed, but requires HZ-9 to be effective, and that is a fix to core Openfire itself.
Greg Thomas
March 1, 2018 at 3:30 PM
Initial analysis;
After the node leaves the cluster, CacheFactory.leftCluster() is called - this attempts to copy all the data out of the clustered caches back in to the default caches.
But, because Hazelcast is shutdown, as soon as an attempt is made to read the clustered data an exception is thrown leaving the whole server (and probably every server in the ex-cluster) in a rather dodgy state.
Steps to reproduce;
Install a fresh Openfire, enable hazelcast clustering.
Login to Openfire, navigate to the "Clustering" page. Select "Disabled", and click "Save Settings".
Expected results
The Clustering page indicates that clustering is disabled.
Actual results
The browser shows a NullPointerException from Openfire. The server stops responding. It is necessary to stop and restart Openfire, at which point the Clustering page indicates that clustering is disabled.
Exception: java.lang.NullPointerException at org.jivesoftware.openfire.admin.decorators.main_jsp._jspService(main_jsp.java:162) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:812) at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:587)