File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Beginning Java and the fly likes Databse session and web session issue Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Databse session and web session issue" Watch "Databse session and web session issue" New topic

Databse session and web session issue


Joined: Dec 02, 2003
Posts: 10
I wish to know whether a database session can be terminated earlier than web session which is binding the database session. The database session is bound to the web session upon database login by:
1. javax.servlet.http.HttpSessionBindingListener;
2. javax.servlet.http.HttpSessionBindingEvent;
Both the database session and web session are set to timeout in 60 minutes.
When we do an experiment to manually terminate the database session after 30 minutes, our expected result is that no record can be added to the database from the web application after 30 minutes. We test this because there is a possiblility that the database session may end earlier than web session for unknow reason.
But our test result shows that record still can be added to database after 30 minutes.
1. What is the cause of this unexpected result ?
2. What is the supposed result ?

Thanks in advance.
Thomas Paul
mister krabs
Ranch Hand

Joined: May 05, 2000
Posts: 13974
Not a beginner's question. Moving to servlets.

Associate Instructor - Hofstra University
Amazon Top 750 reviewer - Blog - Unresolved References - Book Review Blog
I agree. Here's the link:
subject: Databse session and web session issue
It's not a secret anymore!