This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Servlets and the fly likes Session and HttpURLConnection Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Session and HttpURLConnection " Watch "Session and HttpURLConnection " New topic
Author

Session and HttpURLConnection

Prakash Dwivedi
Ranch Hand

Joined: Sep 28, 2002
Posts: 452
Hello Friends,

I want to use java.net.HttpURLConnection class to send request to a servlet. Will the session be maintained on the server if i send another request through this class.

My dobut is that session information is usually stored in cookies(jsessionid), and cookies are maintained by web-browser. But if i am sending HttpRequest through java class, where is it going to store jsessionid (and the servlet has not implemented URLRewritting). WIll it be possible to browse the site using simple java class?


Prakash Dwivedi (SCJP2, SCWCD, SCBCD)
"Failure is not when you fall down, Its only when you don't get up again"
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Session and HttpURLConnection
 
Similar Threads
URLConnection && session state
https and session state
Session management ambiguity
Session Tracking
Session in JSP pages