Hi David,

The problem was interesting. So even Rick made his mind I think it is
beneficial to see if configuration was possible for the requirement.
According to Rick:

>I have an odd requirement where this internal application should
> only be used by one valid user(one session) at a time. (The data
> being worked with in the application would require so many locks
> that's it just easier to restrict it to one user).

The server.xml in Tomcat 4.1.27

<Connector className="org.apache.coyote.tomcat4.CoyoteConnector"
port="80" minProcessors="1" maxProcessors="1"
enableLookups="true" redirectPort="443"
acceptCount="0" debug="0" connectionTimeout="5000"
useURIValidationHack="false" disableUploadTimeout="true" />

"acceptCount" is for how many connections would be queued, right? If one
user is using the connection, maxProcessors is 1, others automatically
can not connect. So this user will use data alone.By setting
acceptCount="0", no other connection will be queued also, right? Cookies
seems not in original requirement. If others cannot connect, there is no
other sessions. It is similar in Tomcat 5, although it uses maxThreads as
name.

John H. Xu

  ----- Original Message -----
  From: "David G. Friedman"
  To: "Struts Users Mailing List"
  Subject: RE: probably a cleaner way... testing for just one user
  Date: Tue, 26 Jul 2005 22:39:57 -0400

  >
  > John,
  >
  > Aren't those for simultaneous threads for the webapp, not to limit
  total
  > sessions/session cookies? I thought that just mean that the jobs
  get queue
  > up and run one at a time in that webapp, i.e. with fewer threads.
  It
  > wouldn't stop having multiple sessionIds for people at any given
  time.
  >
  > Regards,
  > David
  >
  > -----Original Message-----
  > From: John Henry Xu [mailto:[EMAIL PROTECTED]
  > Sent: Tuesday, July 26, 2005 10:35 PM
  > To: Struts Users Mailing List
  > Subject: Re: probably a cleaner way... testing for just one user
  >
  >
  > Rick,
  >
  > In Tomcat, you can set minProcessors="1" maxProcessors="1" in
  > tag (in server.xml file). In Jboss it is the same.
  >
  > What Application server are you using?
  >
  > John H. Xu
  >
  > ----- Original Message -----
  > From: "Rick Reumann"
  > To: "Struts Users Mailing List"
  > Subject: Re: probably a cleaner way... testing for just one user
  > Date: Tue, 26 Jul 2005 22:11:38 -0400
  >
  > >
  > > John Henry Xu wrote the following on 7/26/2005 9:56 PM:
  > > > Can you set maxprocess=1 in web application server
  configuration
  > file?
  > >
  > > I haven't seen that, but I would think there would/should be a
  way
  > > to set up "max sessions" yet googling around hasn't helped. With
  a
  > > combination of a filters and session listeners I've managed to
  get
  > > what I need working, but it's not the cleanest solution.
  > >
  > > -- Rick
  > >
  > >
  >
  ---------------------------------------------------------------------
  > > To unsubscribe, e-mail: [EMAIL PROTECTED]
  > > For additional commands, e-mail: [EMAIL PROTECTED]
  >
  >
  >
  >
  >
  >
  > Jack H. Xu
  > Technology columnist and editor
  >
  > http://www.usanalyst.com
  >
  > http://www.getusjobs.com (The largest free job portal in North
  America)
  >
  > --
  > ___________________________________________________________
  > Sign-up for Ads Free at Mail.com
  > http://promo.mail.com/adsfreejump.htm
  >
  >
  >
  >
  ---------------------------------------------------------------------
  > To unsubscribe, e-mail: [EMAIL PROTECTED]
  > For additional commands, e-mail: [EMAIL PROTECTED]






Jack H. Xu
Technology columnist and editor

http://www.usanalyst.com

http://www.getusjobs.com (The largest free job portal in North America)

-- 
___________________________________________________________
Sign-up for Ads Free at Mail.com
http://promo.mail.com/adsfreejump.htm

Reply via email to