By clicking “Check Writers’ Offers”, you agree to our terms of service and privacy policy. We’ll occasionally send you promo and account related email
No need to pay just yet!
About this sample
About this sample
Words: 525 |
Page: 1|
3 min read
Published: Dec 18, 2018
Words: 525|Page: 1|3 min read
Published: Dec 18, 2018
HTTP protocol is always organized around a clinet sending a request to a server.The client sends the request and the server respones with the response according to the request submitted by the client.Message is nothing but the chunk of data flowing through the network connection used by client while talking with the server. One of the key part of the request is the action that the client ther server to take on its behalf. So every request has a request method and every request is a action or verb that a client is asking the server to take on its behalf.All the Requests are dictated as Request method to be applied on a specific resource on the server. Resource will typically be a path.
Method is used to indicate the server what to do.->the GET method is used for asking the server to get the mentioned resource and return it to us. Basically, it is used for retrieving the content along with status line and headers.->HEAD method is just like the GET but instead of providing the whole resource body it is used for retriving only the headers and the status line.->the POST method is used to send the data to the server by the client for processing or storing the data in its database.->PUT method is used for creating or replacing a resource with the content specified in the body which is in the request i.e. if the resource specified in the URI exists then that resource will be replaced by the body and if the resource in the URI does not exist the that particular resource will be created.
->DELETE is used for deleting a resource mentioned from the server.->CONNECT method is used to establish a connection between a client and a server over HTTP. ->Using OPTION method we can find out various methods supported by the server. So upon receiving the OPTION request the server will return what are the possible methods supported by the server.->TRACE is used to echo the content of the http request back to the client. This is mostly used for the debugging process while developing, to check whether or not the content is altered by the intermediate servers or not.
The safe methods are those methods which do not change the conent of the server i.e it performs only read operation on the server’s database. The methods like GET, HEAD, OPTIONS, and TRACE are safe methods as they returns only with the content and do not update anything on the server side, while the rest all the methods are not safe like POST, PUT, DELETE as they are used to enter, update or delete the content on the server-side.
The idempotent methods are those methods which can be called upon as many as time as possible either once or hundred times but the result will be the same. E.g GET method will every time return the same resource no matter how many times same url is executed. Similarly, HEAD, PUT, DELETE, OPTIONS and TRACE are idempotent methods while POST is not idempotent as calling POST many times will generate false updates or a redundant database.
Browse our vast selection of original essay samples, each expertly formatted and styled