Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

 

 

Span
stylefont-size:2em;font-weight:bold
JAX-RS : Understanding the Basics
 

 

Table of Contents

What is New in JAX-RS 2.1

Reactive Client API

CompletionStage

RxJava Observable

Please see JAX-RS RxJava for more information.

CompletableFuture as a method return value

Please see JAX-RS RxJava for more information about returning RxJava Observable.

Server Sent Events

CXF NIO Extension

Please see JAX-RS NIO for more information about this CXF 3.2.0 extension which is based on the early JAX-RS 2.1 API prototype.

What is New in JAX-RS 2.0

...

One of the best JAX-RS 2.0 features is the support for server-side asynchronous invocations. Please see the AsyncResponse documentation which provides a very good overview of this feature.

See also this test resource.

Typically, the resource method accepting AsyncResponse will either store it and start a new thread to finish the request, the method will return and the invocation will be suspended, then eventually another thread (either the one which initiated an internal job or some other thread) will resume the suspended call. Note in this case the invocation will be suspended indefinitely until it is resumed.

...