我应该注意哪些设置

我应该注意哪些设置

本文介绍了对于Wildfly Standalone-HA群集,我应该注意哪些设置?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试设置Wildfly 9.0.0Final Standanlone服务器的群集.我正在使用httpd2.2.和modcluster1.2.6.在他们之前进行负载平衡.

i am trying to set cluster of Wildfly 9.0.0Final standanlone servers. I am using httpd2.2. and modcluster1.2.6. before them for load balancing.

在我部署可以在链接会话上找到的简单战争专用应用程序之前,集群工作正常复制工作正常.部署后,我加载了put.jsp页面,然后杀死了为其提供页面的服务器.然后我转到加载页面get.jsp,该页面显示了相同的日期和时间,并且我知道该会话已保存,因为此请求是从群集中的其他节点提供的.

Cluster works fine until i am deploying simple war only app that can be found on link Session replication works fine. After deployment i load page put.jsp and then i kill server on which page was served. Then i go and load page get.jsp that shows me same date and hour and i know that session was saved since this request was served from other node in cluster.

在对该基本示例进行成功测试之后,我开始部署自己的Web应用程序.我将标签放在web.xml中并部署了应用程序.它顺利上线,我登录了我的页面.现在,我希望我的登录帐户能够杀死正在服务的节点,并且不会注意到任何事情.杀死服务节点后,我得到了几秒钟404,在同一地址上找不到页面,几秒钟后,我回到了页面,但是会话没有保留,并且我也不再登录,因此会话没有分配给其他节点.

After successful testing on that basic example, i started deploying my own web app. I put tag in web.xml and deployed application. It went live without a problem and i logged in my page. Now i wanted that my logged in account survives killing node that was serving and don't notice a thing.After killing serving node i got for few seconds 404, Page not found on same address, after few seconds i get back my page but session didn't remain, and i not logged in anymore, so session wasn't distributed to other nodes.

为确保我对用户权限进行了编程登录,我还将get.jsp和put.jsp复制到了我的应用程序中并重新部署了它.我首先做的测试也发生了同样的事情.

To make sure that i programmed login of user right i copied also get.jsp and put.jsp to my app and redeploy it. Same thing happened with test i did first.

我的应用是带ejb和网络包装的耳包. Bean都实现了Serializable,并且web.xml中具有可分发标签.还有其他原因吗?

My app is ear package with ejb and web package inside. Beans are all implementing Serializable and web.xml has distributable tag in it. Is there any other reason for this behaviour?

我知道我的节点可以看到对方,而httpd也可以看到两个节点. httpd日志或任何节点日志中都没有错误.

I know that my nodes sees each other and httpd also sees both nodes. There is no error in httpd log or any of nodes logs.

推荐答案

从底部开始逐步构建我的应用程序之后,我发现问题出在使用omnifaces 2.0.在我的应用程序中.无所不知的全能方式阻止了会话的复制或破坏了会话,并且每个请求都有一个新的会话(没有研究为什么要详细说明).对于问题,您不需要在任何bean中使用omnifaces,而只是将其与应用程序一起部署会引起问题.

After building my application bit by bit from bottom, i found out that problem was with using omnifaces 2.0. in my application. Somehow omnifaces prevented session replication or destroy session and every request has new session (didn't research why to details). For problems you don't need to use omnifaces in any bean just deploying it with app is causing problems.

我将omnifaces升级到了新版本2.1.会话复制可以正常工作.

I upgraded omnifaces to new version 2.1. with which session replication works fine.

这篇关于对于Wildfly Standalone-HA群集,我应该注意哪些设置?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-06 09:10