This week's book giveaway is in the Android forum.
We're giving away four copies of Head First Android and have Dawn & David Griffiths on-line!
See this thread for details.
The moose likes Cattle Drive and the fly likes Difference between old & new servlets Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Head First Android this week in the Android forum!
JavaRanch » Java Forums » This Site » Cattle Drive
Bookmark "Difference between old & new servlets" Watch "Difference between old & new servlets" New topic

Difference between old & new servlets

Carol Murphy
village idiot

Joined: Mar 15, 2001
Posts: 1202
The old version of Servlets (before jsp) kept the ArrayList populated even if you stopped the server. When you started up the server again, all of the videos were still there. I've noticed that with the jsp version, every time the server is stopped, when it starts up again the ArrayList is empty. Why is that?
Marilyn de Queiroz

Joined: Jul 22, 2000
Posts: 9056
Are you sure you aren't confusing it with the jdbc assignments? I would be very surprised to learn that your app server kept something in its memory after it was stopped, and since the html was created in the servlet, I don't think that the browser could keep a cached copy of it.
[ May 08, 2006: Message edited by: Marilyn de Queiroz ]

"Yesterday is history, tomorrow is a mystery, and today is a gift; that's why they call it the present." Eleanor Roosevelt
Carol Murphy
village idiot

Joined: Mar 15, 2001
Posts: 1202
That must be it. I must be thinking of the JDBC assignments that used this same video concept. Would this be an example of data being stored only as long as a session stays alive, or is it the fact that the server was shut down? Now I have to experiment some more to see if the videos are still there after I close my browser but don't stop the server.
I agree. Here's the link:
subject: Difference between old & new servlets
jQuery in Action, 3rd edition