This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Cattle Drive and the fly likes Servlets-5 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » This Site » Cattle Drive
Bookmark "Servlets-5" Watch "Servlets-5" New topic
Author

Servlets-5

Michael Matola
whippersnapper
Ranch Hand

Joined: Mar 25, 2001
Posts: 1745
    
    2
I'm confused over the details of session management for Servlets-5. Maybe I'm making things more complicated than they need to be?
If I'm to rely on the built-in session management API, then it's my understanding that I need to associate some object, say a video list, as an attribute of the session object I can get from the request object. And I need to retrieve this associated object each time it gets used in a standard doXXX servlet method.
Right?
Or am I way off in the wrong direction?
(If the above is correct, then the way Servlets-5 goes about sharing the video list is different from both how the instructor's solution shares the video list in Servlets 4a-b and the other common way to go about sharing the video list. Right?)
Or should I just torture Marilyn by submitting what I have written up right now?
Carol Murphy
village idiot
Bartender

Joined: Mar 15, 2001
Posts: 1194
I am embarrassed to admit that I don't understand what you are even asking about! My advice to you is to submit what you have, and let Marilyn go nuts on it!
Marilyn de Queiroz
Sheriff

Joined: Jul 22, 2000
Posts: 9044
    
  10
The video list is shared exactly the same way as it is in Servlets-4b

Making sure the user has a valid session is different.


JavaBeginnersFaq
"Yesterday is history, tomorrow is a mystery, and today is a gift; that's why they call it the present." Eleanor Roosevelt
Michael Matola
whippersnapper
Ranch Hand

Joined: Mar 25, 2001
Posts: 1745
    
    2
I think I've got it all straight now. (Guess it depends on how we interpret "same" and "different"!)
My first pass at this assignment produced some pretty ugly code. Was looking for a strategy check to help decide whether to clean up my existing version or to rethink my whole approach. Took a couple more passes and cleaned it up quite nicely, then submitted.
Carol -- as far as not understanding me, don't worry. Some of my posts to the Cattle Drive forum rank pretty high on the cryptic scale. I was trying to ask a fairly detailed question without giving away too much. (But, hey -- you've passed this assignment already!)
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: Servlets-5
 
Similar Threads
passing an ArrayList from a servlet to JSP
Webservices and Request/Response
DataPool and servlets 5
Scope of an HttpSession
Clarification on JDBC assignments