Does Spark support displaying MUCRoom.serverBroadcast messages?

Spark 3.0.2

I am writing a custom openfire plugin that utilizes MUCRoom.serverBroadcast and I have confirmed with Pidgin XMPP client that these messages show.

I don’t see MUC room broadcast messages show in Spark. Is this a bug or is this just not supported as of Spark 3.0.2?

1 Like

That’s a bug, I’ll fix it today so please tomorrow download the new Spark nightly build Ignite Realtime: Spark Nightly Builds

To reproduce the bug use:
When you start the Spark on the login dialog click on the Advanced button and in the settings select General / Start debugger on startup.
Then you’ll see the XMPP debugger and you may see the received messages. In the Pidgin click on Accounts / select your admin account admin@example.com / Then “Announce Send All” and type your broadcast message.

In the XMPP debugger you’ll see:

<message xmlns="jabber:client" xml:lang="en-US" to="bob@example.com" from="example.com" type="headline">
  <archived xmlns="urn:xmpp:mam:tmp" by="bob@example.com" id="1776343159135152"/>
  <stanza-id xmlns="urn:xmpp:sid:0" id="1776343159135152" by="bob@example.com"/>
  <store xmlns="urn:xmpp:hints"/>
  <body xml:lang="en">Announce</body>
  <subject xml:lang="en">Warning!</subject>
</message>

Click on the Main menu / Help / View logs and you’ll see the stacktrace.

java.lang.NullPointerException: Cannot invoke "String.replace(java.lang.CharSequence, java.lang.CharSequence)" because "s" is null
	at org.jivesoftware.sparkimpl.plugin.alerts.BroadcastPlugin.showAlert(BroadcastPlugin.java:254)
	at org.jivesoftware.sparkimpl.plugin.alerts.BroadcastPlugin.lambda$processStanza$0(BroadcastPlugin.java:211)
org.jivesoftware.sparkimpl.plugin.alerts.BroadcastPlugin.processStanza(BroadcastPlugin.java:193)