Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Jersey 15 01 09

868 views

Published on

Published in: Technology, Education
  • Be the first to comment

  • Be the first to like this

Jersey 15 01 09

  1. 1. Jersey, reference implementation of JAX-RS Paul.Sandoz@Sun.Com http://blogs.sun.com/sandoz Sun Microsystems 1
  2. 2. HEAD /Jersey • Open source production quality Reference Implementation > https://jersey.dev.java.net/ > http://wikis.sun.com/display/Jersey/Main • 1.0.1 in December, 1.0.2 in February GET started > GET the JAX-RS overview guide > GET the dependencies > GET the samples > • Blogs: Paul, Marc, Jakub, Aquarium Sun Confidential: Internal Only 2
  3. 3. GET /Glassfish/v3/Prelude Sun Confidential: Internal Only 3
  4. 4. GET /NetBeans/6.5 Sun Confidential: Internal Only 4
  5. 5. GET /Samples • Many samples are provided with the release > Atom, JAXB, JSON, Scala, Spring, WADL, … > Using GlassFish (+embedded) and Grizzly • Download the 1.0.1 samples zip > Samples are maven-based > Works with NetBeans 6.x + maven plugin > Individual sample zip file are also available – e.g. Sparklines, Mandel Sun Confidential: Internal Only 5
  6. 6. GET /Involved • Ask/answer questions, propose fixes/features > mailto:users@jersey.dev.java.net http://markmail.org/search/?q=list%3Anet.java.dev.jersey.users Sun Confidential: Internal Only 6
  7. 7. GET /Jersey-1.0.1/Client API The API • Easier than HttpURLConnection! • Reuses JAX-RS API • Many samples contain tests using this API • White paper will be available soon for registered • users Sun Confidential: Internal Only 7
  8. 8. GET /Jersey-1.0.1/Spring API • The API and Sample > Spring 2.0.x or 2.5.x • XML configuration or Auto-wiring • An instance of resource class or a provider class can be a Spring bean (AOP-proxied or not) > No explicit Jersey-based registration required • Singleton, “prototype”, per-request or per-session scopes are supported Sun Confidential: Internal Only 8
  9. 9. GET /Jersey-1.0.1/JAXB with JAXB • The API and Sample • Better more “natural” JSON documents than using mapped or badgerfish convention • A resource method can return XML or JSON: @GET @Produces({“application/xml”, “application/json”}) public Bean get() { Bean b = … return b } Sun Confidential: Internal Only 9
  10. 10. GET /Jersey-1.0.1/MIME multipart • The API • Readers and writers for processing MIME multipart messages > multipart/mixed > multipart/form-data • Body parts reuse JAX-RS/Jersey readers/writers > JAXB could be used (XML or JSON) Sun Confidential: Internal Only 10
  11. 11. GET /Jersey-1.0.next Jersey client API using Apache HTTP client • Atom support using Apache Abdera • Improved JAXB support with JSON • Resource specific request/response filters • • Guice 2.0 integration, when released! • WebDAV support • Comet support with Atmosphere Sun Confidential: Internal Only 11
  12. 12. Jersey, reference implementation of JAX-RS Paul.Sandoz@Sun.Com http://blogs.sun.com/sandoz Sun Microsystems 12

×