openfire asmack java.lang.IllegalStateException: Not connected to server.错误解决办法

来源:互联网 发布:苏州方正软件 编辑:程序博客网 时间:2024/06/11 03:57


openfire服务器端解决办法:

“服务器设置”--“安全设置”---将“客户端安全联接”中由“非必须”,修改为“自定义”,另外把“旧的SSL方式”和“TLS方式”都设置为无效。


ConnectionConfiguration config = new ConnectionConfiguration(serverHost);

config.setReconnectionAllowed(true);      
config.setCompressionEnabled(false);
config.setSecurityMode(ConnectionConfiguration.SecurityMode.disabled);       
config.setSASLAuthenticationEnabled(false);
0 0
原创粉丝点击