Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Is REST practical ?  RSS feed

 
Hussein Baghdadi
clojure forum advocate
Bartender
Posts: 3479
Clojure Mac Objective C
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi.
Please correct me if I'm wrong but REST employs HTTP GET method, right ?
Does this make REST practical in the real world ?
SOAP web services use the HTTP request body which can carry alot of data while get method allows only for -maybe- 256 chars.
Thanks.
 
Leonard Richardson
author
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
John,

A client for a RESTful service only uses the GET method to "get"
data. The only data it must send along with GET is the name of the
thing it wants to "get". Even a 256-character limit usually leaves
enough room to say what you want to get, and most servers put the
limit much higher.

When you're sending a lot of data, you don't use GET, because you're
probably not "get"ting anything: you're telling the server to process your
data. For that you use POST or PUT (it depends on what exactly you're
doing). The data you're sending doesn't go in the URL. Rather, it goes into
the body of the HTTP request: the same place the SOAP envelope goes when you
POST to a SOAP endpoint. This data can be as long as neccessary.
 
Hussein Baghdadi
clojure forum advocate
Bartender
Posts: 3479
Clojure Mac Objective C
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It seems to me that REST is about changing how we thinking about the web applications.
Is this a good idea?
 
Leonard Richardson
author
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think it is. The web has an object model that we're generally not using.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!