resources - Openfire服务器,多个连接,route.all-resources不起作用

标签 resources chat openfire strophe

我们使用http-bind我们的聊天应用程序使用 BOSH 和 Openfire (3.8.2) 作为后端,Strope 库 (JS) 作为前端。

每个用户通过连接获得指定的唯一资源。这意味着用户可以同时登录不同的设备/浏览器(多个连接,例如 <a href="https://stackoverflow.com/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="4b3e382e390b2e332a263b272e65282426" rel="noreferrer noopener nofollow">[email protected]</a>/resource1<a href="https://stackoverflow.com/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="e095938592a08598818d908c85ce838f8d" rel="noreferrer noopener nofollow">[email protected]</a>/resource2 等)。理想情况下,我们希望将消息发送到所有连接的资源。

我们设置route.all-resources setting="true"所有用户资源的连接优先级相同,但行为根本没有改变(仅收到最后连接的用户资源的聊天消息)。

有人可以提出解决方案或想法来解决这个问题吗?

谢谢

最佳答案

您可能需要 route.all-resourcesroute.really-all-resources

route.really-all-resources = true 将以非负优先级向所有 session 发送消息 route.all-resources = true 将向所有共享最高非负优先级的 session 发送消息

其来源位于https://github.com/igniterealtime/Openfire/blob/master/src/java/org/jivesoftware/openfire/spi/RoutingTableImpl.java#L567

关于resources - Openfire服务器,多个连接,route.all-resources不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20396169/

相关文章:

java - 访问我的java应用程序中的.txt文件并将其直接显示给用户

c# - 如何获取存储在资源中的图像的 Uri

multithreading - 2013年WCF长投票

macos - 饼图库

python - 在 django/tastypie 资源中传递请求变量

php - 如何使用 PHP + JS +(MySQL?)+(AJAX?)进行快速、轻量级、经济的在线聊天

android - unity android wifi socket通信通过Android DLL

centos - 如何使用 IPTables 将流量重新路由到本地连接管理器或主 xmpp 服务 (Openfire)

security - 如何在 Openfire 上配置 OTR?

php - 如何使用php绕过XMPP Openfire服务器中的登录过程?