background preloader

REST Web Service

Facebook Twitter

Learn REST: A Tutorial: 1. What is REST? REST stands for Representational State Transfer.

Learn REST: A Tutorial: 1. What is REST?

(It is sometimes spelled "ReST".) It relies on a stateless, client-server, cacheable communications protocol -- and in virtually all cases, the HTTP protocol is used. REST is an architecture style for designing networked applications. The idea is that, rather than using complex mechanisms such as CORBA, RPC or SOAP to connect between machines, simple HTTP is used to make calls between machines.

In many ways, the World Wide Web itself, based on HTTP, can be viewed as a REST-based architecture. 6460-restful-java-web-services-sample-chapter-restful-web-services-design. REST with Java (JAX-RS) using Jersey. Jersey contains a REST client library which can be used for testing or to build a real client in Java.

REST with Java (JAX-RS) using Jersey

The usage of this library is demonstrated in the following tutorial. Create a new Java gradle project with com.vogella.jersey.first.client as top-level package name and add following dependency to your build.gradle file to import the Jersey dependencies. JAX-RS: Advanced Topics and Example - The Java EE 6 Tutorial. Building RESTful Web Services with JAX-RS - The Java EE 6 Tutorial.