File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Accesing a server from the same browser with different domain URLs creates 2 different sessions

 
David Rocks
Ranch Hand
Posts: 162
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I have a tomcat server (7.0.35) that takes in requests from different domain URLs, the content shown on the page differs depending on the domain url.

The problem I am having is that if I hit the same jsp on the same server from the same browser with a different domain url I get a different session made, I would like the session to remain over the different domains for functional reasons.

I have tried modifying the server configuration. single sign on, crossContext etc etc but I am guessing, I cannot see anything explicitly that refers to this scenario, most of the documentation refers to cross context authentication.

Any thoughts on the matter would be appreciated.

Thanks


 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64178
83
IntelliJ IDE Java jQuery Mac Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Cookies are domain-specific, so sessions are too.
 
David Rocks
Ranch Hand
Posts: 162
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Think I am resigning myself to the cookie/url/session split now.

Thought I could get something from manipulating the hosts and/or server config.
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13045
6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You could always implement your own session equivalent collection class and use the user ID (assuming its the same for all URLs) to track it.
Bill

 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic