| 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?
| |
|
| 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();
|
|
|
|