Re: access to all sessions
Hi Leon, How bad of an idea is it to set privileged=true in my context? Wouldn't this give me access to the things I want (and much more that I probably don't want access to)? Our environment is such that maybe this isn't totally out of the question, we run TC in a piece of hardware to serve content to the attached touchscreen. There is only ever one webapp running, ROOT, and that is really all that will ever be running. Tim Leon Rosenberg wrote: It depends on your definition of easier... you could provide your own session manager with your own session implementation, which supports such a mechanism or patch the existing StandartSession.java. I don't know whether you'd call it easy :-) Leon On Thu, Dec 4, 2008 at 8:09 PM, Timothy J Schumacher <[EMAIL PROTECTED]> wrote: Hi Leon, Thanks for the info. So, if I simply wanted to tell TC to invalidate all sessions is there something easier I could do? Tim Leon Rosenberg wrote: Hello Tim, there is no easy and direct way to do it. What you can do is to create a SessionListener (http://java.sun.com/javaee/5/docs/api/javax/servlet/http/HttpSessionListener.html), register it as listener in the web.xml and store references to the sessions upon creation somewhere (read map). But beware, you have to be cautious a) not to create a memory leak by not letting tomcat to remove outdated sessions and b) synchronize accesses to your map and sessions without creating dead locks (since 1.4 doesn't have all the fancy concurrency stuff). regards Leon On Thu, Dec 4, 2008 at 7:32 PM, Timothy J Schumacher <[EMAIL PROTECTED]> wrote: Hi, I have TC 5.0.12 and java 1.4.1_04. Unfortunately, I am stuck using these versions for now... I am trying to figure out how to access/manipulate all the sessions for my web app. I guess I want something similar to the manager application, but I don't want to have to run the manager application. Does anyone know of a good reference to learn more about how this works? I looked a little bit at the docs but it was not clear to me how to access this data. Thanks! Tim - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: access to all sessions
LambaProbe's (http://www.lambdaprobe.org) features overview says : "Ability to expire selected sessions". Not sure if this is what you're looking for? Cheers. On Thu, 2008-12-04 at 12:09 -0700, Timothy J Schumacher wrote: > Hi Leon, > > Thanks for the info. So, if I simply wanted to tell TC to invalidate > all sessions is there something easier I could do? > > Tim > > Leon Rosenberg wrote: > > Hello Tim, > > > > there is no easy and direct way to do it. What you can do is to create > > a SessionListener > > (http://java.sun.com/javaee/5/docs/api/javax/servlet/http/HttpSessionListener.html), > > register it as listener in the web.xml and store references to the > > sessions upon creation somewhere (read map). > > But beware, you have to be cautious a) not to create a memory leak by > > not letting tomcat to remove outdated sessions and b) synchronize > > accesses to your map and sessions without creating dead locks (since > > 1.4 doesn't have all the fancy concurrency stuff). > > > > regards > > Leon > > > > On Thu, Dec 4, 2008 at 7:32 PM, Timothy J Schumacher > > <[EMAIL PROTECTED]> wrote: > > > >> Hi, > >> > >> I have TC 5.0.12 and java 1.4.1_04. Unfortunately, I am stuck using these > >> versions for now... > >> > >> I am trying to figure out how to access/manipulate all the sessions for my > >> web app. I guess I want something similar to the manager application, but > >> I > >> don't want to have to run the manager application. Does anyone know of a > >> good reference to learn more about how this works? I looked a little bit > >> at > >> the docs but it was not clear to me how to access this data. > >> > >> Thanks! > >> Tim > >> > >> > >> > >> - > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: [EMAIL PROTECTED] > >> > >> > >> > > > > - > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: access to all sessions
It depends on your definition of easier... you could provide your own session manager with your own session implementation, which supports such a mechanism or patch the existing StandartSession.java. I don't know whether you'd call it easy :-) Leon On Thu, Dec 4, 2008 at 8:09 PM, Timothy J Schumacher <[EMAIL PROTECTED]> wrote: > Hi Leon, > > Thanks for the info. So, if I simply wanted to tell TC to invalidate all > sessions is there something easier I could do? > > Tim > > Leon Rosenberg wrote: >> >> Hello Tim, >> >> there is no easy and direct way to do it. What you can do is to create >> a SessionListener >> >> (http://java.sun.com/javaee/5/docs/api/javax/servlet/http/HttpSessionListener.html), >> register it as listener in the web.xml and store references to the >> sessions upon creation somewhere (read map). >> But beware, you have to be cautious a) not to create a memory leak by >> not letting tomcat to remove outdated sessions and b) synchronize >> accesses to your map and sessions without creating dead locks (since >> 1.4 doesn't have all the fancy concurrency stuff). >> >> regards >> Leon >> >> On Thu, Dec 4, 2008 at 7:32 PM, Timothy J Schumacher >> <[EMAIL PROTECTED]> wrote: >> >>> >>> Hi, >>> >>> I have TC 5.0.12 and java 1.4.1_04. Unfortunately, I am stuck using >>> these >>> versions for now... >>> >>> I am trying to figure out how to access/manipulate all the sessions for >>> my >>> web app. I guess I want something similar to the manager application, >>> but I >>> don't want to have to run the manager application. Does anyone know of a >>> good reference to learn more about how this works? I looked a little bit >>> at >>> the docs but it was not clear to me how to access this data. >>> >>> Thanks! >>> Tim >>> >>> >>> >>> - >>> To unsubscribe, e-mail: [EMAIL PROTECTED] >>> For additional commands, e-mail: [EMAIL PROTECTED] >>> >>> >>> >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: access to all sessions
Hi Leon, Thanks for the info. So, if I simply wanted to tell TC to invalidate all sessions is there something easier I could do? Tim Leon Rosenberg wrote: Hello Tim, there is no easy and direct way to do it. What you can do is to create a SessionListener (http://java.sun.com/javaee/5/docs/api/javax/servlet/http/HttpSessionListener.html), register it as listener in the web.xml and store references to the sessions upon creation somewhere (read map). But beware, you have to be cautious a) not to create a memory leak by not letting tomcat to remove outdated sessions and b) synchronize accesses to your map and sessions without creating dead locks (since 1.4 doesn't have all the fancy concurrency stuff). regards Leon On Thu, Dec 4, 2008 at 7:32 PM, Timothy J Schumacher <[EMAIL PROTECTED]> wrote: Hi, I have TC 5.0.12 and java 1.4.1_04. Unfortunately, I am stuck using these versions for now... I am trying to figure out how to access/manipulate all the sessions for my web app. I guess I want something similar to the manager application, but I don't want to have to run the manager application. Does anyone know of a good reference to learn more about how this works? I looked a little bit at the docs but it was not clear to me how to access this data. Thanks! Tim - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: access to all sessions
Hello Tim, there is no easy and direct way to do it. What you can do is to create a SessionListener (http://java.sun.com/javaee/5/docs/api/javax/servlet/http/HttpSessionListener.html), register it as listener in the web.xml and store references to the sessions upon creation somewhere (read map). But beware, you have to be cautious a) not to create a memory leak by not letting tomcat to remove outdated sessions and b) synchronize accesses to your map and sessions without creating dead locks (since 1.4 doesn't have all the fancy concurrency stuff). regards Leon On Thu, Dec 4, 2008 at 7:32 PM, Timothy J Schumacher <[EMAIL PROTECTED]> wrote: > Hi, > > I have TC 5.0.12 and java 1.4.1_04. Unfortunately, I am stuck using these > versions for now... > > I am trying to figure out how to access/manipulate all the sessions for my > web app. I guess I want something similar to the manager application, but I > don't want to have to run the manager application. Does anyone know of a > good reference to learn more about how this works? I looked a little bit at > the docs but it was not clear to me how to access this data. > > Thanks! > Tim > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
access to all sessions
Hi, I have TC 5.0.12 and java 1.4.1_04. Unfortunately, I am stuck using these versions for now... I am trying to figure out how to access/manipulate all the sessions for my web app. I guess I want something similar to the manager application, but I don't want to have to run the manager application. Does anyone know of a good reference to learn more about how this works? I looked a little bit at the docs but it was not clear to me how to access this data. Thanks! Tim - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]