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 Architect Certification (SCEA/OCMJEA) and the fly likes HTTP Protocol 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 » Certification » Architect Certification (SCEA/OCMJEA)
Bookmark "HTTP Protocol" Watch "HTTP Protocol" New topic
Author

HTTP Protocol

Ashish Garg
Ranch Hand

Joined: Jul 04, 2004
Posts: 68
Is Http a connectionless or connection base protocol. As per my understanding it is connectionless. Keeping KEEP-ALIVE of http 1.1 still I feel its a connection less protocol.

Please suggest, as one of the mock exam I got it as Connection Base.


SCJP1.2, SCWCD1.4, SCBCD1.3, SCBCD 5.0, SCDJWS, SCEA, IBM Certified SOA Associate
Rahul Bhattacharjee
Ranch Hand

Joined: Nov 29, 2005
Posts: 2308
Hi Ashish,

I could not get the meaning of connectionless and connectionbase protocol.
Please correct me if I am wrong.

I gues you are asking something about stateless nature of HTTP.Is that you are asking ?

First of all , it has to establish a connection , no matter whether its stateless or stateful.


Rahul Bhattacharjee
LinkedIn - Blog
Ashish Garg
Ranch Hand

Joined: Jul 04, 2004
Posts: 68
Hi Rahul, This is not given in the question. What I understand whether the connection persist between mulitple request between web server and client, or web server uses diffrent connection for each request via connectionless and connectionbase.

But not very sure as I am also confused with the question.
Question is what is HTTP
1) Stateless
2) Stateful
3) Connectionless
4) Connectionbase
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41029
    
  43
HTTP is stateless, so if only one answer is correct, then that's the one.

Connection can mean a number of different things, so without context it's hard to say what is meant here. Fundamentally, HTTP is based on TCP/IP, which is connection-less, like all store-and-forward network architectures. But HTTP operates on a higher level than TCP, and abstracts away all the intermediate store/forward steps, thereby creating the illusion of an actual connection (even more so with the keep-alive feature).


Ping & DNS - my free Android networking tools app
Ashish Garg
Ranch Hand

Joined: Jul 04, 2004
Posts: 68
Question asked select two.
Frank Kuepper
Ranch Hand

Joined: Mar 16, 2007
Posts: 45
As Ulf said: HTTP for sure is stateless. From the connectionless/based options connection based makes most sense.

But it seems to me, like that is a really poorly designed question in the mock exam you've got - I wouldn't expect this question in the real thing What mock exam is it?


SCEA (93%/93%)
Rahul Bhattacharjee
Ranch Hand

Joined: Nov 29, 2005
Posts: 2308
Originally posted by Ulf Dittmer:
HTTP is based on TCP/IP, which is connection-less


For the question that Ashish Garg asked ,I would go with Ulf Dittmer.

But TCP/IP is not connection less , though IP is connectionless.

As TCP is operation at a higher layer then that of IP , it has its own mechanism with which it maintains connection.

As a whole I consider TCP/IP of connection oriented nature.
Marc Peabody
pie sneak
Sheriff

Joined: Feb 05, 2003
Posts: 4727

Check out this on Wikipedia.

IP is not connection based but TCP (which sits on top of IP) is. And since HTTP is on top of TCP, HTTP is also connection based. By "connection" it means that the sender and receiver establish a handshake (as defined by TCP) and guarantee that the entire message gets received.

The correct answers are stateless and connection based.


A good workman is known by his tools.
Ashish Garg
Ranch Hand

Joined: Jul 04, 2004
Posts: 68
Thanks all for your inputs.
Kedar Bhawarthi
Greenhorn

Joined: May 14, 2004
Posts: 8
Hi Ashish!

HTTP is Stateless and Connectionbase protocol.
I am sure that no body has doubt about its Statelessness.

Now as we say, we have various protocol stack. And 'connection-orientedness' or 'connectionless-ness' of layer n layer protocol is not really dependent on these properties of n-1 layer protocol.
In other words you can build connection-oriented communication layer over connectionless layer (like some chatting application do over UDP protocol)or you can ....
build connectionless communication layer over connection-oriented layer .... something which HTTP do!!!
hence it is connectionbase protocol.
 
jQuery in Action, 2nd edition
 
subject: HTTP Protocol
 
Similar Threads
HTTP
HTTP and concept of connectionless
Question about HTTP
Session Tracking
HTTP and concept of connectionless