Cannot set XMPPTCPConnectionConfiguration to a connection once connected to do a login.
I build configuration using
XMPPTCPConnectionConfiguration.XMPPTCPConnectionConfigurationBuilder gconfig = XMPPTCPConnectionConfiguration.builder(); gconfig.setRosterLoadedAtLogin(false); gconfig.setSendPresence(false); gconfig.setDebuggerEnabled(true); gconfig.setRosterLoadedAtLogin(true); gconfig.setSecurityMode(ConnectionConfiguration.SecurityMode.disabled); gconfig.setHost(SERVER_IP); gconfig.setPort(SERVER_PORT); gconfig.setServiceName(datacenter); gconfig.setUsernameAndPassword("TEMP","TEMP"); gconfig.setResource("TEMP"); Roster.setDefaultSubscriptionMode(Roster.SubscriptionMode.accept_all); SmackConfiguration.setDefaultPacketReplyTimeout(10000); SmackConfiguration.DEBUG_ENABLED = DEBUG_VERSION; xmpptcpConnectionConfiguration =gconfig.build(); Later connect using config XMPPTCPConnection xmpptcpConnection = new XMPPTCPConnection(xmpptcpConnectionConfiguration); xmpptcpConnection.connect(); Later register/create account using user provided input name and password. AccountManager accountManager = AccountManager.getInstance(ConnectionsManager.getInstance().getConnection()); accountManager.createAccount(username, pass, accountattribs); PROBLEM STARTS HERE gconfig.setUsernameAndPassword(user,secret); gconfig.setResource(gRes); xmpptcpConnectionConfiguration=gconfig.build(); ConnectionsManager.getInstance().getConnection().login(); on Login it takes the old username and password its not taking the new connection user and password I have to discconect and re-build config with new username and password and then login . Can we not tweak something to allow login with params as it was before for non-anonymous logins ?