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

smack.SmackException$ ConnectionException thrown by XMPPConnection.connect();

$
0
0

i want to connect to a ejabberd server that worked with asmack 0.8.10.

but now with new version 4.0.0 the code does not work and throw an exception

 

the code is :

 

ConnectionConfiguration mConnectionConfiguration = new ConnectionConfiguration("some address (like google.com)", 5222);

                    mConnectionConfiguration.setDebuggerEnabled(true);

XMPPConnection mConnection = new XMPPTCPConnection(mConnectionConfiguration);

                    mConnection.connect(); //(here throw an exception)

 

and exception is:

 

06-17 12:02:56.924: W/System.err(10622): org.jivesoftware.smack.SmackException$ConnectionException

06-17 12:02:56.924: W/System.err(10622):           at org.jivesoftware.smack.tcp.XMPPTCPConnection.connectUsingConfiguration(XMPPTCPC onnection.java:431)

06-17 12:02:56.940: W/System.err(10622):           at org.jivesoftware.smack.tcp.XMPPTCPConnection.connectInternal(XMPPTCPConnection. java:799)

06-17 12:02:56.940: W/System.err(10622):           at org.jivesoftware.smack.XMPPConnection.connect(XMPPConnection.java:391)

06-17 12:02:56.940: W/System.err(10622):           at com.example.testchat.MainActivity.test(MainActivity.java:121)

06-17 12:02:56.940: W/System.err(10622):           at com.example.testchat.MainActivity.access$0(MainActivity.java:56)

06-17 12:02:56.940: W/System.err(10622):           at com.example.testchat.MainActivity$1.run(MainActivity.java:34)

06-17 12:02:56.940: W/System.err(10622):           at java.lang.Thread.run(Thread.java:856)

 

What could be the Problem?

Thanks


Viewing all articles
Browse latest Browse all 11593

Trending Articles