powered by Jive Software

Strange problem with Wildfire Server Connection

Hi,

I’'m trying to test out some functionality of wildfire server.

I’'m using Wildfire 2.5.0 with smack-dev-2006-03-08 using jdk 1.4.2_08

I try the following in a loop (20 times):

  1. Open a connection.

  2. Login. (in signon command)

  3. Close the connection. (in signoff command)

/*

try{

for(int i = 0; i<20; i++){

Command command = new Signon();

command.execute(wfMsg);

System.out.println("Login successful " + i);

command = new Signoff();

command.execute(wfMsg);

System.out.println(“Logout successful”);

}

}Catch(Exception e){

e.printStackTrace();

}

*/

And I get the following Exception:

java.net.SocketException: Socket closed

at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:99)

at java.net.SocketOutputStream.write(SocketOutputStream.java:136)

at sun.nio.cs.StreamEncoder$CharsetSE.writeBytes(StreamEncoder.java:336)

at sun.nio.cs.StreamEncoder$CharsetSE.implFlushBuffer(StreamEncoder.java:404)

at sun.nio.cs.StreamEncoder$CharsetSE.implFlush(StreamEncoder.java:408)

at sun.nio.cs.StreamEncoder.flush(StreamEncoder.java:152)

at java.io.OutputStreamWriter.flush(OutputStreamWriter.java:213)

at java.io.BufferedWriter.flush(BufferedWriter.java:230)

at org.jivesoftware.smack.PacketWriter.writePackets(PacketWriter.java:249)

at org.jivesoftware.smack.PacketWriter.access$000(PacketWriter.java:34)

at org.jivesoftware.smack.PacketWriter$1.run(PacketWriter.java:69)

java.net.SocketException: Software caused connection abort: recv failed

at java.net.SocketInputStream.socketRead0(Native Method)

at java.net.SocketInputStream.read(SocketInputStream.java:129)

at com.sun.net.ssl.internal.ssl.InputRecord.a(DashoA12275)

at com.sun.net.ssl.internal.ssl.InputRecord.read(DashoA12275)

at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)

at com.sun.net.ssl.internal.ssl.SSLSocketImpl.j(DashoA12275)

at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(DashoA12275)

at org.jivesoftware.smack.XMPPConnection.proceedTLSReceived(XMPPConnection.java:10 53)

at org.jivesoftware.smack.PacketReader.parsePackets(PacketReader.java:317)

at org.jivesoftware.smack.PacketReader.access$000(PacketReader.java:43)

at org.jivesoftware.smack.PacketReader$1.run(PacketReader.java:63)

Not connected to server.

java.lang.IllegalStateException: Not connected to server.

at org.jivesoftware.smack.XMPPConnection.sendPacket(XMPPConnection.java:672)

at org.jivesoftware.smack.NonSASLAuthentication.authenticate(NonSASLAuthentication .java:54)

at org.jivesoftware.smack.SASLAuthentication.authenticate(SASLAuthentication.java: 213)

at org.jivesoftware.smack.XMPPConnection.login(XMPPConnection.java:410)

at com.bt.platform.services.jabber.command.Signon.execute(Signon.java:35)

at com.bt.platform.jabber.test.TestJabberConnection.main(TestJabberConnection.java :39)

java.lang.IllegalStateException: Not connected to server.

at org.jivesoftware.smack.XMPPConnection.sendPacket(XMPPConnection.java:672)

at org.jivesoftware.smack.NonSASLAuthentication.authenticate(NonSASLAuthentication .java:54)

at org.jivesoftware.smack.SASLAuthentication.authenticate(SASLAuthentication.java: 223)

at org.jivesoftware.smack.XMPPConnection.login(XMPPConnection.java:410)

at com.bt.platform.services.jabber.command.Signon.execute(Signon.java:35)

at com.bt.platform.jabber.test.TestJabberConnection.main(TestJabberConnection.java :39)

Any help?

Thanks in advance,

Partha.

Forgot to mention: this happenes randomly after a few successful log in.

have you tried testing with jdk 1.5?

The JDK 1.5 may be helpful.

Nops that didnt help…

Wildfire anywa comes bundled with 1.5 …so no question of changing it …

I was running smack on 1.5 …as thats my default JVM settings…

So this leads me to believe that Wildfire has some major probs with performance/threading/io

Folks you would need to resolve it …coz its gonna drive me crazy very soon …