Constructor and Description |
---|
ExecutorServiceManager(ExecutorService executor,
Duration shutdownPeriod,
String poolName) |
Modifier and Type | Method and Description |
---|---|
ExecutorService |
getExecutor() |
String |
getPoolName() |
Duration |
getShutdownPeriod() |
void |
start()
Starts the object.
|
void |
stop()
Stops the object.
|
String |
toString() |
public ExecutorServiceManager(ExecutorService executor, Duration shutdownPeriod, String poolName)
public void start() throws Exception
Managed
public void stop() throws InterruptedException, Exception
stop
in interface Managed
InterruptedException
- This is thrown if the thread executing this method is
interrupted while awaiting executor tasks to complete.Exception
- if something goes wrong.public ExecutorService getExecutor()
public Duration getShutdownPeriod()
public String getPoolName()
Copyright © 2019. All rights reserved.