powered by Jive Software

Keep disconnecting


My code is not working as I want it to be. I want to stay connected but for some reason it connects and then disconnects the next second…My objective is to keep my account present “online” till I execute disconnect…

here is my code

public static void main(String[] args) {

XMPPConnection connection = new XMPPConnection(“localhost”);

try {


connection.login(“aje”, “newmedia”);

} catch (XMPPException e) { e.printStackTrace(); }