Top Banner
1 Jersey, reference implementation of JAX-RS [email protected] http://blogs.sun.com/sandoz Sun Microsystems 1
12

Jersey 15 01 09

Apr 16, 2017

Download

Technology

Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Jersey 15 01 09

1

Jersey, reference implementation of JAX-RS

[email protected]://blogs.sun.com/sandozSun Microsystems

1

Page 3: Jersey 15 01 09

Sun Confidential: Internal Only 3

GET /Glassfish/v3/Prelude

Page 4: Jersey 15 01 09

Sun Confidential: Internal Only 4

GET /NetBeans/6.5

Page 5: Jersey 15 01 09

Sun Confidential: Internal Only 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

Page 6: Jersey 15 01 09

Sun Confidential: Internal Only 6

GET /Involved

• Ask/answer questions, propose fixes/features> mailto:[email protected]

http://markmail.org/search/?q=list%3Anet.java.dev.jersey.users

Page 7: Jersey 15 01 09

Sun Confidential: Internal Only 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

Page 8: Jersey 15 01 09

Sun Confidential: Internal Only 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

Page 9: Jersey 15 01 09

Sun Confidential: Internal Only 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

}

Page 10: Jersey 15 01 09

Sun Confidential: Internal Only 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)

Page 11: Jersey 15 01 09

Sun Confidential: Internal Only 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

Page 12: Jersey 15 01 09

12

Jersey, reference implementation of JAX-RS

[email protected]://blogs.sun.com/sandozSun Microsystems

12