WebSphere Portal Server - ServletContext needed

This is Interesting: Free IT Magazines  
Home > Archive > WebSphere Portal Server > August 2004 > ServletContext needed





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author ServletContext needed
bephinney

2004-08-06, 5:55 pm

I need to obtain a reference to the ServletContext object.

I am extending LogoutUserAuth and need a reference to the ServletContext in the LogoutUserAuth.onUserSessionTimeout(HttpSession aSession) method.

The catch is that I am developing on WPS 4.2.1 which runs on J2EE 1.2 which does not have a HttpSession.getServletContext() method.

What are my options?

2004-08-08, 5:54 pm

This is NOT supported code but it does give you access to the servletcontext.

import com.ibm.wps.engine.RunData;
RunData run= RunData.from(request);
run.getContext();

bephinney

2004-08-09, 5:58 pm

Thanks for the tip.

The problem, however, is that there is no request being made at my point of concern. The session has timed-out and the server is doing some clean-up.

The only object I am passed is an HttpSession.

Any other possibilities?

> This is NOT supported code but it does give you
> access to the servletcontext.
>
> import com.ibm.wps.engine.RunData;
> RunData run= RunData.from(request);
> run.getContext();



Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com