Rana,

Are you using a Servlet Container that is compatible with the Java Servlet 2.3 
API? If so, this sort of thing should be implemented as a Servlet Filter:

http://java.sun.com/j2ee/sdk_1.3/techdocs/api/index.html

We use this in our product to verify authentication credentials and such. 
Works quite nicely. 

If that is not an option for you, you can use an Application Scoped map which 
you can access from within an Action class using:

this.getServlet().getServletContext().setAttribute("USER_MAP", userMap);

Map userMap =
        this.getServlet().getServletContext().getAttribute("USER_MAP");

Or something like that.

-jason

> I am working on a similar monitor class to track the users logged into a
> web application at any given time. This information is displayed when user
> logs into the web application. 
> 
> i am trying to accomplish this using ServletContextListener and
> HttpSessionAttributeListener classes in the servlet API.
> 
> Any help/ideas about tracking users currently logged into a web application
> are most welcome.
> 
> Thanks,
> Rana.

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to