final public void disconnect(String agentId) {
try {
State state = agentFactory.getStateFactory().get(agentId);
ArrayNode conns = null;
if (state.containsKey("_XMPP_Connections")) {
conns = (ArrayNode) JOM.getInstance().readTree(
(String) state.get("_XMPP_Connections"));
}
if (conns != null) {
for (JsonNode conn : conns) {