• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Servlet HttpSession in webobjects?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Servlet HttpSession in webobjects?


  • Subject: Re: Servlet HttpSession in webobjects?
  • From: Lachlan Deck <email@hidden>
  • Date: Wed, 13 Feb 2008 16:47:36 +1100

No - I think the answer was (from Chuck) to log out the request as it comes in and see what headers/formValues you receive and go from there.

On 13/02/2008, at 4:45 PM, Jeff Schmitz wrote:

What you most likely want to do is call your DA and manually pass the session ID as a query parameter, for instance:

The trouble is, I have no control over this. The session ID gets passed as it gets passed, nothing I can do about it I don't think because it's not my app. I just give it the link, and it decides how the session ID is passed. That being the case, looks like the answer is I'm out of luck, right?

Thanks,
Jeff

On Feb 12, 2008, at 11:26 PM, Mike Schrag wrote:

It is going to be sending a session identifier. This is going to be either in the form values or in the HTTP headers.
I don't see it in the URL, so I'm guessing it must come over as a form variable. If so, using my last e-mail as an example j2ee equivalent of what I want to do, i.e.:

String sessionKey = (String) session.getAttribute ("otherj2eeAppSession");

should I be able to get it simply by doing:

String sessionKey = (String) this.request().formValueForKey ("otherj2eeAppSession");
1) If you're calling session.getAttribute("otherj2eeAppSession") in your j2ee app to get this value, there's no way to get this value from your WO app. A session attribute is a key-value pair _inside_ of an HttpSession, which you don't have (and cannot get without literally serializing the session and sending it over in some custom way).

2) The only thing you can possibly get is one of:
2a) a form parameter that you manually pass to your DA as a query string parameter
2b) a form parameter that you manually pass to your DA via a post parameter
2c) a cookie value provided both of your apps are on the same host and the cookie is configured at the root


What you most likely want to do is call your DA and manually pass the session ID as a query parameter, for instance:

http://yourhost.com/cgi-bin/WebObjects/YourApp.woa/wa/ yourDirectAction?otherj2eeAppSession=xyz

at which point, yes you could call request().stringFormValueForKey ("otherj2eeAppSession") and get the value.

ms
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
@mac.com


This email sent to email@hidden

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40gmail.com


This email sent to email@hidden

with regards, --

Lachlan Deck



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Servlet HttpSession in webobjects?
      • From: Chuck Hill <email@hidden>
References: 
 >Re: AJAX WebObjects Integration (From: Jeff Schmitz <email@hidden>)
 >Servlet HttpSession in webobjects? (From: Jeff Schmitz <email@hidden>)
 >Re: Servlet HttpSession in webobjects? (From: Lachlan Deck <email@hidden>)
 >Re: Servlet HttpSession in webobjects? (From: Jeff Schmitz <email@hidden>)
 >Re: Servlet HttpSession in webobjects? (From: Lachlan Deck <email@hidden>)
 >Re: Servlet HttpSession in webobjects? (From: Jeff Schmitz <email@hidden>)
 >Re: Servlet HttpSession in webobjects? (From: Mike Schrag <email@hidden>)
 >Re: Servlet HttpSession in webobjects? (From: Jeff Schmitz <email@hidden>)
 >Re: Servlet HttpSession in webobjects? (From: Chuck Hill <email@hidden>)
 >Re: Servlet HttpSession in webobjects? (From: Jeff Schmitz <email@hidden>)
 >Re: Servlet HttpSession in webobjects? (From: Mike Schrag <email@hidden>)
 >Re: Servlet HttpSession in webobjects? (From: Jeff Schmitz <email@hidden>)

  • Prev by Date: Re: Servlet HttpSession in webobjects?
  • Next by Date: Re: Servlet HttpSession in webobjects?
  • Previous by thread: Re: Servlet HttpSession in webobjects?
  • Next by thread: Re: Servlet HttpSession in webobjects?
  • Index(es):
    • Date
    • Thread