部署在JBoss应用服务器共享会话之间2 Java EE应用程序 [英] Share Session between 2 Java EE applications deployed in JBoss AS

查看:139
本文介绍了部署在JBoss应用服务器共享会话之间2 Java EE应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有2这就需要共享一个登录的用户一些常见的与用户相关的数据的Java EE应用程序。

I have 2 Java EE applications which need to share some common user related data of a logged in user.

反正是有通过它我可以从一个应用程序在会话中存储数据和检索数据的第二个应用程序?即类似的东西在.NET粘性会话。

Is there anyway by which I can store this data in the session from one application and retrieve that data in a second application? I.e. something similar to sticky sessions in .NET.

推荐答案

两个独立的Java EE应用程序将有单独的会话数据。 如果他们是在同一个域,你想分享几个属性,那么你可以使用一个Cookie,并设置属性到Cookie,并阅读每个Web应用程序。

Two separate Java EE applications will be having separate session data. If they are on the same domain and you want to share couple of attributes, then you could use a cookie and set attributes into the cookie and read them in each web app.

这篇关于部署在JBoss应用服务器共享会话之间2 Java EE应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆