Network Deployment (Distributed operating systems), v8.0 > Develop and deploying applications > Develop web services - RESTful services
Develop JAX-RS web applications
- Get started with IBM JAX-RS
JAX-RS is a collection of interfaces and Java annotations that simplifies development of server-side REST applications. By using JAX-RS technology, Representational State Transfer (REST) applications are easier to develop and easier to consume when compared to other types of distributed systems.
- Set up a development environment for JAX-RS applications
The application server provides command-line tools to develop web services clients and implementations that are based on the Java API for RESTful Web Services (JAX-RS) specification. We must set up your development environment before you start developing web services.
- Assembly tools
WAS supports assembly tools that you can use to develop, assemble, and deploy Java EE modules.
- Directory conventions
References in product information to WAS_HOME, PROFILE_ROOT, and other directories imply specific default directory locations. This topic describes the conventions in use for WAS.
- Configure the web.xml file for JAX-RS servlets
The web.xml file contains information about the structure and external dependencies of web components in the module and describes how the components are used at run time. To enable the web container to run Java API for RESTful Web Services (JAX-RS) applications, you can configure the web.xml file to point directly to the IBM JAX-RS servlet. When using servlets, you can define a servlet path in the web.xml file that is appended to the base URL.
- Configure the web.xml file for JAX-RS filters
The web.xml file contains information about the structure and external dependencies of web components in the module and describes how the components are used at run time.
To enable the web container to run Java API for RESTful Web Services (JAX-RS) applications, you can configure the web.xml file to define filters that indicate the possible URLs on which the filter can be invoked.
- Configure JAX-RS web applications
- Implement clients using the Apache Wink REST client
We can use the Apache Wink REST client to send requests and process responses from RESTful services. We can use the client API in Java programs to communicate with web services.
- Implement a client using the unmanaged RESTful web services JAX-RS client
WAS provides a thin Java Platform, Standard Edition 6 (Java SE 6) RESTful web services client runtime to enable application developers to quickly and easily create JAX-RS client applications. The Thin Client for JAX-RS with WAS is a stand-alone Java SE 6 client environment that enables running unmanaged JAX-RS RESTful web services client applications in a non-WebSphere environment to invoke JAX-RS RESTful web services that are hosted by the application server.
- Migrate a Feature Pack for Web 2.0 JAX-RS application to WebSphere v8
When packaging an application for the Feature Pack for Web 2.0, manually make the Java API for RESTful Web Services (JAX-RS) run time available on the application CLASSPATH. A common way of doing this is placing the JAX-RS runtime JAR files in the WEB-INF/lib directory of the WAR module. In v8, the JAX-RS runtime environment is native to the application server. It is no longer necessary to manually add the path of the runtime libraries on the CLASSPATH. Migrating Web 2.0 applications to the native runtime environment simplifies packaging and deployment, and allows for future updates to take advantage of Java EE integration features.
- Disable the JAX-RS runtime environment
There are cases where disable the Java API for RESTful Web Services (JAX-RS) runtime environment. When disabling the JAX-RS runtime environment, JAX-RS features are not available, including base JAX-RS runtime capabilities, EJB runtime integration, Java Contexts and Dependency Injection (JCDI) runtime integration, and Servlet 3.0 web container integration.