Experts,
please review the changes proposed in the async API that I juts pushed to the public code repository:
http://java.net/projects/jax-rs-spec/sources/git/revision/ee9baeab1acbe8f16cdae025f16b75d8185a302e
The changes I am proposing are meant to make the API easier to use and understand by the end users. Here's the summary:
- declarative and programmatic suspend defined as exclusive (use either @Suspend or ExecutionContext.suspend(...), but
not both)
- new setSuspendTimeout(...) method added to the ExecutionContext (to compensate for the change above)
- ExecutionContext.suspend(...) methods do not return Future<?> anymore
- new isDone(), isSuspended(), isCancelled() methods added to the ExecutionContext (to compensate for the change above)
- async example updated to match the new API
Thank you,
Marek