+

Search Tips   |   Advanced Search

Use Atom content in JAX-RS application requests and responses

We can use the Atom Syndication Format (Atom) to format web feeds, which communicate news and updates of episodic information about websites. Using Atom content in JAX-RS applications, we can take advantage of web content syndication that provides the same decentralized, dynamic mechanisms for adding new metadata and content supported by RSS, but does so in a way that helps protect core interoperability between implementations.

Atom is an XML-based document format that describes lists of related information known as feeds. Feeds are composed of a number of items, known as entries, each with an extensible set of attached metadata. For example, each entry has a title. The primary use for Atom format is the syndication of web content such as weblogs and news headlines to websites, as well as publishing content directly to user agents.

The IBM JAX-RS library provides a JAXB Atom model that uses the standard JAXB entity provider for consuming and producing Atom feeds and Atom entries in a JAX-RS application.

The JAXB Atom model is included in the org.apache.wink.common.model.atom and org.apache.wink.common.model.synd Java packages in the Apache Wink-based IBM JAX-RS library JAR. An application can use classes such as a JAXB annotated org.apache.wink.common.model.atom.AtomFeed to read and write ATOM feeds.

  1. Configure the development environment.

  2. Define resources in JAX-RS web applications.

  3. Configure the JAX-RS application.

  4. Implement JAXB-based ATOM content for requests and responses Implement JAXB-based ATOM content for requests and responses

  5. Assemble JAX-RS web applications.

  6. Deploy JAX-RS web applications.


Results

You have developed and deployed a JAX-RS web application on the application server that uses Atom content for requests and responses.


Subtopics


Related tasks

  • Use the JAXB-based Atom model for requests and responses

  • Web services specifications and APIs