[jsr236-spec users] [jsr236-experts] On ManagedTaskListener related APIs in MES and MSES
- From: Anthony Lai <
- Subject: [jsr236-spec users] [jsr236-experts] On ManagedTaskListener related APIs in MES and MSES
- Date: Wed, 05 Dec 2012 14:43:19 -0800
- List-id: <jsr236-experts.concurrency-ee-spec.java.net>
There is recently a suggestion on the MES and MSES APIs that I would
like to get opinions from the expert group.
The idea was instead of having 7 new APIs in the ManagedExecutorService
and 4 in ManagedScheduledExecutorService whose only difference from the
ones in the super class in java.util.concurrent package was the addition
of an extra parameter for ManagedTaskListener, could we replace them
with an addTaskListener and removeTaskListener to the
- Much fewer new APIs in MES and MSES
- Easier to register same ManagedTaskListener to monitor events for all
task submissions. For example, an application can register a single
ManagedTaskListener to an MES receive all events related to task
- Becomes awkward when need to specify a different ManagedTaskListener
for each task submission
- Management of list of task listeners, especially if the MES is shared
across multiple applications and that applications that registers the
listener may be undeployed.
I tend to prefer the current APIs, but I would like to bring this up and
see if anyone have different opinions or suggestions.