Tag Archives: J2SE

Java EE Concurrency API Tutorial


Java EE Concurrency API Tutorial

This is a sample chapter taken from the Practical Java EE 7 development on WildFly book edited by Francesco Marchioni.

This chapter discusses about the new Java EE Concurrency API (JSR 236) which outlines a standard way for executing tasks in parallel on a Java EE Container using a set of Managed resources. In order to describe how to use this API in your applications, we will follow this roadmap:

  • A short introduction to the Concurrency Utilities
  • How to leverage asynchronous tasks using the ManagedExecutorService
  • How to schedule tasks at specific times using the ManagedScheduledExecutorService
  • How to create dynamic proxy objects which add contextual information available in Java EE environment
  • How to use the ManagedThreadFactory to create managed threads to be used by your applications