I have two web appplications 1. test.war 2. birt.war
I set cookies in http response header for birt url
Cookie cookie = new Cookie(GlobalConstants.JSESSIONID, request.getSession(false).getId());
cookie.setPath("/birt");
response.addCookie(cookie);
Then I open birt url with appropriate url parameters in javascript like
window.open(url);
But the next request from birt I get have new JSESSIONID. This works in JBoss6 AS.
I am able to see the cookies in developer console
**Request 1**
http://192.168.10.7:8080/test
Cookies are
Response Cookie :
JSESSIONID :
value = 9G6bzvsF-ijbynGTmbWp7Ml4E5KFVHiEPlSflh16
Path = /birt
**Request 2**
http://192.168.10.7:8080/birt
Cookies are
Response Cookie :
JSESSIONID :
value = **xrLqLb5-8Vvqlkk2GKyapqwJZm5dJnyvFQOia9IM.node1** // new cookie
Path = /birt
Request Cookie :
JSESSIONID :
value = 9G6bzvsF-ijbynGTmbWp7Ml4E5KFVHiEPlSflh16
Path = /birt
Also I tried adding in both wars in jboss-all.xml but even that does not work.
<shared-session-config xmlns="urn:jboss:shared-session-config:1.0">
<session-config>
<cookie-config>
<path>/</path>
</cookie-config>
</session-config>
</shared-session-config>