powered by Jive Software

Having trouble with spark and smack combination

  1. checked out the spark(rivision #10959) and smack(rivision #10950)

  2. biult smack and got smack.jar, smackx-debug.jar, smackx-jingle.jar, smackx.jar

  3. rmoved bundled smack.jar, smackx-debug.jar, smackx-jingle.jar, smackx.jar from the build path of spark project

  4. added built smack.jar, smackx-debug.jar, smackx-jingle.jar, smackx.jar to the build path of spark project

  5. launched the spark

I got some errors corresponded to login action such as following…

Header 1
Exception in thread “Thread-5” java.lang.Error: Unresolved compilation problem:
The method login(String, String, String) in the type XMPPConnection is not applicable for the arguments (String, String, String, boolean)

at org.jivesoftware.LoginDialog$LoginPanel.login(LoginDialog.java:886)
at org.jivesoftware.LoginDialog$LoginPanel.access$0(LoginDialog.java:794)
at org.jivesoftware.LoginDialog$LoginPanel$2.construct(LoginDialog.java:632)
at org.jivesoftware.spark.util.SwingWorker$2.run(SwingWorker.java:131)
at java.lang.Thread.run(Unknown Source)

There are some others also…

Please someone let me know what I did wrong or the revision number of smack which works fine with Spark(#10959)


Smack 3.1.0 has changed login methods inside Spark. Now, this line:

connection.login(getUsername(), getPassword(), resource, false)

should be implemeted this way:


connection.login(getUsername(), getPassword(), resource)

config is a ConnectionConfiguration and should be changed before constructing connection variable: “connection = new XMPPConnection(config,this);”

Update this changes into Spark code and it should work

Thanks @JJGL

Got another error after changing the “login” method

In “org.jivesoftware.spark.ui.RetryPanel.java”

there is a mehtod like

Header 1
private void reconnect() {
try {
if (closedOnError) {
else {
catch (Exception ex) {

But the thing is there is no static forceReconnection() method in or above ReconnectionManager

How can I fix this?

Thanks again in advance