public final class IoEnvironment
extends oracle.pgx.api.internal.ApiObject
| Modifier and Type | Method and Description |
|---|---|
int |
getNumThreadsPerTask()
Blocking version of
getNumThreadsPerTaskAsync(). |
PgxFuture<java.lang.Integer> |
getNumThreadsPerTaskAsync() |
java.util.Map<java.lang.String,java.lang.Object> |
getValues()
Blocking version of
getValuesAsync(). |
PgxFuture<java.util.Map<java.lang.String,java.lang.Object>> |
getValuesAsync() |
void |
reset()
Blocking version of
resetAsync(). |
PgxFuture<java.lang.Void> |
resetAsync()
reset the sub environment to the configured default values
|
void |
setNumThreadsPerTask(java.lang.Integer numThreadsPerTask)
Blocking version of
setNumThreadsPerTaskAsync(Integer). |
PgxFuture<java.lang.Void> |
setNumThreadsPerTaskAsync(java.lang.Integer numThreadsPerTask)
Sets the current value for the number of threads used for IO tasks
|
java.lang.String |
toString() |
<T> T |
withNumThreadsPerTask(int numThreads, java.util.function.Supplier<PgxFuture<T>> asyncSupplier)
Blocking version of
withNumThreadsPerTaskAsync(int, Supplier). |
<T> PgxFuture<T> |
withNumThreadsPerTaskAsync(int numThreads, java.util.function.Supplier<PgxFuture<T>> asyncRequest)
Executes the given asynchronous request with the number of threads used for IO tasks
|
public int getNumThreadsPerTask()
throws java.util.concurrent.ExecutionException,
java.lang.InterruptedException
getNumThreadsPerTaskAsync(). Calls getNumThreadsPerTaskAsync() and waits for returned PgxFuture to complete.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<java.lang.Integer> getNumThreadsPerTaskAsync()
EnterpriseSchedulerConfig.Field.NUM_IO_THREADS_PER_TASK
public void setNumThreadsPerTask(java.lang.Integer numThreadsPerTask)
throws java.util.concurrent.ExecutionException,
java.lang.InterruptedException
setNumThreadsPerTaskAsync(Integer). Calls setNumThreadsPerTaskAsync(Integer) and waits for returned PgxFuture to complete.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.public PgxFuture<java.lang.Void> setNumThreadsPerTaskAsync(java.lang.Integer numThreadsPerTask)
numThreadsPerTask - the number of threads to use for IO tasksEnterpriseSchedulerConfig.Field.NUM_IO_THREADS_PER_TASK
public <T> T withNumThreadsPerTask(int numThreads,
java.util.function.Supplier<PgxFuture<T>> asyncSupplier)
throws java.util.concurrent.ExecutionException,
java.lang.InterruptedException
withNumThreadsPerTaskAsync(int, Supplier). Calls withNumThreadsPerTaskAsync(int, Supplier) and waits for returned PgxFuture to complete.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.public <T> PgxFuture<T> withNumThreadsPerTaskAsync(int numThreads, java.util.function.Supplier<PgxFuture<T>> asyncRequest)
numThreads - the temporary number of threads for IO tasksasyncRequest - an asynchronous request
public final java.util.Map<java.lang.String,java.lang.Object> getValues()
throws java.util.concurrent.ExecutionException,
java.lang.InterruptedException
getValuesAsync(). Calls getValuesAsync() and waits for returned PgxFuture to complete.java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.public final PgxFuture<java.util.Map<java.lang.String,java.lang.Object>> getValuesAsync()
public final void reset()
throws java.util.concurrent.ExecutionException,
java.lang.InterruptedException
java.lang.InterruptedException - if the caller thread gets interrupted while waiting for completion.java.util.concurrent.ExecutionException - if any exception occurred during asynchronous execution. The actual exception will be nested.public final PgxFuture<java.lang.Void> resetAsync()
public java.lang.String toString()
toString in class java.lang.ObjectCopyright © 2017 Oracle Corp. All Rights Reserved.