473,434 Members | 1,458 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,434 software developers and data experts.

seting Session expiry time

1
Hi,

I am new in java, i needed help in setting the expiry time for the session. I need the session to expire after 3 minutes, then show a table of the pages i visited during the 3 minutes and also show how many time each page was visited.

I would appreciate any help.

Thanks.
sazan.
Apr 28 '10 #1
1 1746
jkmyoung
2,057 Expert 2GB
Use a thread, and then use its join method. Create a custom thread class, and put your pre-work in it's the run function.
Expand|Select|Wrap|Line Numbers
  1. Thread task = new CustomThread();
  2. task.start(); // calls the run() function.
  3.  
  4. task.join(180000); // wait 180k ms = 180 s = 3 min
  5.  
  6. Calculate stats here.
  7.  
Admittedly, I am weak in threading, so this may not be the best way to do it.
Apr 28 '10 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Brett Porter | last post by:
Howdy, For a challenge I took on a very large project and have decided to develop it on Red Hat, using PHP and MySQL. I am pleased to say that using Red Hat, PHP and MySQL has been extremely...
8
by: John Smith | last post by:
Hi, I am using a custom Session Handler. session_set_save_handler is working well. But i want to read the data direct from the database. My problem: php don't uses the standard serialize...
8
by: ndsoumah | last post by:
hello guys I'm trying to get access to variables I put in a session variable from another page and it fails... here's the exact situation main file page1.php
14
by: windandwaves | last post by:
Hi Folk Forgive me for asking such a basic question... I have a site where I want to track the user from start till end... To do this, I have setup the following structure for each page,...
0
by: Thotatri | last post by:
hi, I am facing a session time out problem once after installing .net framework 1.1 . The problem is session is getting expired on frequently say 5 mts like that.I have good configuration &...
0
by: nbdy9(nospam) | last post by:
I have a ASP.Net website (mobile). From time to time the browser popup the following message. Anyway to catch the error and redirect to my start page? saying, login.aspx? Thanks. ...
6
by: somaskarthic | last post by:
Hi This is somas here. I asked query about detecting the browser close event using javascript. I want to detect the event only when the X button in the top right corner is clicked and not else...
6
by: laredotornado | last post by:
Hi, When a user logs into our site, we create a session variable to denote the session is active and another to denote who is logged in. Once the user closes the browser and re-opens it, the...
2
by: Muhammed Soyer | last post by:
Hi, I wonder whether any good mailing lists for C# and dotnet technologies exist or not. Do you follow any mailing lists for dotnet ? Thanks
2
by: fijsolam1981 | last post by:
Hi, I had created a web application where Session expiry was set to 2,000 minutes in IIS. in web config i had given like this <sessionState timeout="2,000" mode="InProc"></sessionStatebut MY web...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.