Re: Servlet help needed!

2003-07-12 Thread Jason Coleman
For me when you close the browser the session is invalidated...

also, tomcat also has a 30min default expiry for inactive sessions
(elimating the need for below)

- Original Message -
From: "Rick Roberts" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>
Sent: Saturday, July 12, 2003 11:30 PM
Subject: Re: Servlet help needed!


> //Invalidate session if inactive for more than 1 hour
> if(!session.isNew()){ // skip new sessions
>Date hourAgo = new Date(System.currentTimeMillis() - 60*60*1000);
>Date accessed = new Date(session.getLastAccessedTime());
>
>if(accessed.before(hourAgo)) session.invalidate();
> }
>
> FIkayo Otun wrote:
> > Good day(Sir/ma), I am a java programmer just starting to explore the
J2ee platform. I use jdk1.4.2... and tomcat to develop and deploy my
servlet. I however need a way to end my session when ever I close my
browser.  I noticed when I close my browser my session will still be on. I
am currently ussing servlet to develop an online apllication. I this I realy
need to find A solution to my problem.
> >
> > Fikayo, from Nigeria
>
> --
> ***
> * Rick Roberts*
> * Advanced Information Technologies, Inc. *
> ***
>
>
> -
> 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: Servlet help needed!

2003-07-12 Thread Rick Roberts
//Invalidate session if inactive for more than 1 hour
if(!session.isNew()){ // skip new sessions
  Date hourAgo = new Date(System.currentTimeMillis() - 60*60*1000);
  Date accessed = new Date(session.getLastAccessedTime());
  if(accessed.before(hourAgo)) session.invalidate();
}
FIkayo Otun wrote:
Good day(Sir/ma), I am a java programmer just starting to explore the J2ee platform. I use jdk1.4.2... and tomcat to develop and deploy my servlet. I however need a way to end my session when ever I close my browser.  I noticed when I close my browser my session will still be on. I am currently ussing servlet to develop an online apllication. I this I realy need to find A solution to my problem.

Fikayo, from Nigeria
--
***
* Rick Roberts*
* Advanced Information Technologies, Inc. *
***
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Servlet help needed!

2003-07-12 Thread FIkayo Otun
Good day(Sir/ma), I am a java programmer just starting to explore the J2ee platform. I 
use jdk1.4.2... and tomcat to develop and deploy my servlet. I however need a way to 
end my session when ever I close my browser.  I noticed when I close my browser my 
session will still be on. I am currently ussing servlet to develop an online 
apllication. I this I realy need to find A solution to my problem.

Fikayo, from Nigeria
-- 
__
Sign-up for your own FREE Personalized E-mail at Mail.com
http://www.mail.com/?sr=signup

CareerBuilder.com has over 400,000 jobs. Be smarter about your job search
http://corp.mail.com/careers


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



Re: Servlet help needed

2001-05-04 Thread Noel E. Lecaros

Hi, Ante

You actually don't need to edit anything in server.xml if your app uses
default settings.  Just drop your app's directory tree into the webapp
subdir and start Tomcat.  Which web.xml file did you make changes in
anyway?  You're not supposed to edit the web.xml in the conf subdir!

Hope this helps.

Regards,
Noel Lecaros

BTW, just a friendly reminder.  Please don't post in HTML.  Not everyone
on this list uses an HTML-enabled mail reader.



Ante Sabo wrote:

>  I cannot deploy my servlet application to run by Tomcat. I editet
> server.xml and web.xml files as described in documentation to set up
> my contextes, but all I got on my screen is Tomcat error
> message: Mapping context with unregisterred servlet   What this
> message is meaning to me. I beleive I made everything in script files
> needed to register my sevlet, and also registering context, and it
> won't work. Can you give me the link to a place where I can find some
> explanation what is needed to register servlet application.  Only way
> I can register it is to put it under /webapps/examples directory. That
> way I don't have even to register it - it works, but is that a real
> solution?  With many thanks, regards,Ante Sabo Zagreb
> UniversityFaculty of organization & informaticsVaraždin,
> Croatia http://www.foi.hr http://www.foi.hr/~asabo




Servlet help needed

2001-04-24 Thread Ante Sabo



 
I cannot deploy my servlet application to run by 
Tomcat. I editet server.xml and web.xml files as described in documentation to 
set up my contextes, but all I got on my screen is Tomcat error message:
 
Mapping context with unregisterred servlet 

 
 
What this message is meaning to me. I beleive I 
made everything in script files needed to register my sevlet, and also 
registering context, and it won't work. Can you give me the link to a place 
where I can find some explanation what is needed to register servlet 
application. 
 
 
Only way I can register it is to put it under 
/webapps/examples directory. That way I don't have even to register it - it 
works, but is that a real solution? 
 
 
With many thanks,
 
regards,
Ante Sabo
 
Zagreb University
Faculty of organization & 
informatics
Vara¾din, Croatia
 
http://www.foi.hr
 
http://www.foi.hr/~asabo