• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

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

 
Ranch Hand
Posts: 162
  • 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


 
Sheriff
Posts: 67266
170
Mac Mac OS X IntelliJ IDE jQuery Java
  • 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
  • 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.
 
Author and all-around good cowpoke
Posts: 13078
6
  • 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

 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!