wood burning stoves
The moose likes Architect Certification (SCEA/OCMJEA) and the fly likes Doubt  in HTTP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Architect Certification (SCEA/OCMJEA)
Bookmark "Doubt  in HTTP" Watch "Doubt  in HTTP" New topic

Doubt in HTTP

somkiat puisungnoen
Ranch Hand

Joined: Jul 04, 2003
Posts: 1312
I'm read in some document,

It's said ::

HTTP is connection less.

and in some document said ::

HTTP is connection base.

Please explain to me what choice is correct ... ???

Java Developer, Thailand
Ramon Gill
Ranch Hand

Joined: May 15, 2003
Posts: 344
Hi Somkiat,
HTTP is a protocol that can be used to send HTML pages between browser and server. It is 'stateless' in that it doesn't remember anything about the previous request.

D. Rose
Ranch Hand

Joined: Apr 25, 2003
Posts: 215
HTTP is reuest/response based statelss protocol i.e No state is maintained across requests.

If we look definition of 'connection' in HTTP 1.1 RFC

A transport layer virtual circuit established between two programs
for the purpose of communication.

So connection based/connection less term is generally applied to transport levels protocols ( e.g TCP/IP is connection based while UDP is connectionless).
HTTP is not a trasnport layer protocol so I think connection based/connection less does not make any sense. Applicable terms are statfeul/stateless.
somkiat puisungnoen
Ranch Hand

Joined: Jul 04, 2003
Posts: 1312
thank you very much.
Dan Drillich
Ranch Hand

Joined: Jul 09, 2001
Posts: 1183
Pete Morgan spoke about it in his notes at http://www.sarahandpete.com/work/SCEAexamnotes.pdf

HTTP 1.0 (Hyper Text Transfer Protocol) Port 80. Built on top of TCP/IP. Stateless, connection less and directional. Client opens a connection (using a URL � the direction) and sends request to the server, the server responds using the same connection, then the connection is closed. It is up to the client to optionally maintain the session (through cookies or URL re-writing).

HTTP 1.1 (Hypertext Transfer Protocol) Port 80. Same as HTTP 1.0 except there is an option to keep the connection alive from request to request. This would be known as connection oriented if it weren't for the fact that either side can potentially drop the connection at any time (Apache does after 15 seconds), as such it is still 'connection-less'. However, some people think it is connect oriented because you need a connection to be open to do a request at all. I disagree, but I get the impression this is what Sun thinks, I suppose that is what counts for the exam at least, it is very confusing.


William Butler Yeats: All life is a preparation for something that probably will never happen. Unless you make it happen.
I agree. Here's the link: http://aspose.com/file-tools
subject: Doubt in HTTP
It's not a secret anymore!