Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #28528
| Path | csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.fsmpi.rwth-aachen.de!newsfeed1.swip.net!news.astraweb.com!border5.a.newsrouter.astraweb.com!border2.nntp.ams.giganews.com!Xl.tags.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!local2.nntp.ams.giganews.com!nntp.bt.com!news.bt.com.POSTED!not-for-mail |
|---|---|
| NNTP-Posting-Date | Sun, 18 May 2014 05:13:37 -0500 |
| Date | Sun, 18 May 2014 11:13:37 +0100 |
| From | lipska the kat <lipskathekat@example.com> |
| User-Agent | Mozilla/5.0 (X11; Linux x86_64; rv:16.0) Gecko/20121010 Thunderbird/16.0.1 |
| MIME-Version | 1.0 |
| Newsgroups | comp.lang.java.programmer |
| Subject | Re: share data between two tomcat contexts? |
| References | <ll675j$4rn$1@news.m-online.net> <MZqdnW2ubo69nurOnZ2dnUVZ8rSdnZ2d@giganews.com> <ll7gok$ghl$1@news.m-online.net> |
| In-Reply-To | <ll7gok$ghl$1@news.m-online.net> |
| Content-Type | text/plain; charset=ISO-8859-1; format=flowed |
| Content-Transfer-Encoding | 7bit |
| Message-ID | <B82dnaOLrq5MGuXOnZ2dnUVZ8jadnZ2d@bt.com> (permalink) |
| Lines | 48 |
| X-Usenet-Provider | http://www.giganews.com |
| X-AuthenticatedUsername | NoAuthUser |
| X-Trace | sv3-15DlGQhJmFcVPhXKd9GEYwlbCbx1B62TAes3S82tXAucRYWi++iEmtG2RrHcgLltM8e5A3+QjZGb6y4!6BzQFaJW56gPJoc1H4EQTnMEEecWTlFJKwA60MuWlyfWN0U3UtYnC1jUk/RYKHMEVY570MVzGj0e |
| X-Complaints-To | abuse@btinternet.com |
| X-DMCA-Complaints-To | abuse@btinternet.com |
| X-Abuse-and-DMCA-Info | Please be sure to forward a copy of ALL headers |
| X-Abuse-and-DMCA-Info | Otherwise we will be unable to process your complaint properly |
| X-Postfilter | 1.3.40 |
| X-Original-Bytes | 3082 |
| Xref | csiph.com comp.lang.java.programmer:28528 |
Show key headers only | View raw
On 17/05/14 12:22, Laura Schmidt wrote: > On 05/17/2014 08:35 AM, Leif Roar Moldskred wrote: >> Laura Schmidt <ls@mailinator.com> wrote: >>> Hi, >>> >>> I want to share some data between two tomcat applications running on the >>> same server. >>> >> >> Are there performance demands that prevents you from having one >> application just make HTTP requests to the other and ask for the data >> when it needs it? > > Well, the first application is an existing legacy application where > users can login. > > When logged in, they are informed about a relaunch of the application > and they can follow a link to it. > > Within the new application I would like to know the identity of the user > who is coming from the legacy application. This is why I would like to > access the other one's sesson If all you want is the identity(username) of the logged in user you can get it from the request. When the user clicks the link to the new app they actually end up at a servlet in the legacy app, in the servlet you can get the login name by calling HttpServletRequest#getRemoteUser() You then build your request dispatcher to forward the request to a resource in the new app, appending the username to the request string or adding it as an attribute, maybe you could encrypt the username at this point. when the request arrives at the new app you extract the username ... and 'Roberts your relative', you know the username of the user that logged into the legacy app. Completely insecure of course but it depends on the situation. and I have no idea if you can actually forward to a different app in this way as I've never tried it. -- lipska the kat - treacherous feline. Proudly nominated for IPOTY 2014 - LIGAF GNU/Linux user #560883 - linuxcounter.net
Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
share data between two tomcat contexts? Laura Schmidt <ls@mailinator.com> - 2014-05-17 01:32 +0200
Re: share data between two tomcat contexts? markspace <markspace@nospam.nospam> - 2014-05-16 16:41 -0700
Re: share data between two tomcat contexts? Laura Schmidt <ls@mailinator.com> - 2014-05-17 02:19 +0200
Re: share data between two tomcat contexts? markspace <markspace@nospam.nospam> - 2014-05-16 17:40 -0700
Re: share data between two tomcat contexts? Laura Schmidt <ls@mailinator.com> - 2014-05-17 08:16 +0200
Re: share data between two tomcat contexts? Josip Almasi <joe@vrspace.org> - 2014-05-17 09:29 +0200
Re: share data between two tomcat contexts? Arne Vajhøj <arne@vajhoej.dk> - 2014-05-16 19:45 -0400
Re: share data between two tomcat contexts? Robert Klemme <shortcutter@googlemail.com> - 2014-05-17 12:46 +0200
Re: share data between two tomcat contexts? leif.roar@invalid.com (Leif Roar Moldskred) - 2014-05-17 01:35 -0500
Re: share data between two tomcat contexts? Laura Schmidt <ls@mailinator.com> - 2014-05-17 13:22 +0200
Re: share data between two tomcat contexts? lipska the kat <lipskathekat@example.com> - 2014-05-17 13:04 +0100
Re: share data between two tomcat contexts? leif.roar@invalid.com (Leif Roar Moldskred) - 2014-05-17 08:25 -0500
Re: share data between two tomcat contexts? "Chris Uppal" <chris.uppal@metagnostic.REMOVE-THIS.org> - 2014-05-17 17:21 +0100
Re: share data between two tomcat contexts? Robert Klemme <shortcutter@googlemail.com> - 2014-05-18 10:12 +0200
Re: share data between two tomcat contexts? lipska the kat <lipskathekat@example.com> - 2014-05-18 11:13 +0100
Re: share data between two tomcat contexts? Brixomatic <brixomatic@yahoo.com> - 2014-05-22 18:58 +0200
Re: share data between two tomcat contexts? "Chris Uppal" <chris.uppal@metagnostic.REMOVE-THIS.org> - 2014-05-17 11:11 +0100
csiph-web