如何在集群环境下使用JSF2.0视图作用域?
我想在集群环境中使用JSF2.0。我正在构建一个 JPA2.0 + Spring 3.0 + JSF2.0 堆栈。我知道如何复制会话范围的 bean。但是如何复制视图作用域 bean 呢?我从这里将视图范围插入 Spring 3.0 http:// cagataycivici.wordpress.com/2010/02/17/port-jsf-2-0s-viewscope-to-spring-3-0/
这个想法与JEE6 服务器上的 JS2.0 - 将一个 bean 放入视图映射中 (FacesContext.getCurrentInstance().getViewRoot().getViewMap()
)
问题是: 我已在节点 1 上打开index.xhtml
。 View-scoped
bean 已创建。我点击了一些东西,postback
请求到达了节点 2 - 那里的视图不存在。
集群环境下可以吗?我应该只使用会话和请求范围吗?
另一方面,JSF 视图状态在集群环境中可能无法正常工作。如何在集群上使用JSF?
I want to use JSF2.0 in cluster environment. I'm building a JPA2.0 + Spring 3.0 + JSF2.0 stack. I know how to replicate session scoped beans. But how to replicate view scoped beans? I plugged view scope into Spring 3.0 from here
http://cagataycivici.wordpress.com/2010/02/17/port-jsf-2-0s-viewscope-to-spring-3-0/
The idea is the same as in JS2.0 on JEE6 server - put a bean into the view map (FacesContext.getCurrentInstance().getViewRoot().getViewMap()
)
The problem is :
I've opened index.xhtml
on node 1. View-scoped
bean was created. I clicked something and the postback
request got onto node 2 - where the view doesn't exist.
Is it possible to have this in cluster environment? Should I use only session and request
scope?
On the other hand JSF view-state may not work properly in cluster environment. How to use JSF on cluster?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论