@Incubating interface WorkerConfiguration : Describable, ActionConfiguration
Represents the configuration of a worker. Used when submitting an item of work to the WorkerExecutor.
workerExecutor.submit(RunnableWorkImpl.class) { WorkerConfiguration conf -> conf.isolationMode = IsolationMode.PROCESS forkOptions { JavaForkOptions options -> options.maxHeapSize = "512m" options.systemProperty 'some.prop', 'value' options.jvmArgs "-server" } classpath configurations.fooLibrary conf.params = [ "foo", file('bar') ] }
Since
3.5
abstract fun classpath(files: MutableIterable<File>): Unit
Adds a set of files to the classpath associated with the worker. |
|
abstract fun forkOptions(forkOptionsAction: Action<in JavaForkOptions>): Unit
Executes the provided action against the JavaForkOptions object associated with this builder. |
|
abstract fun getClasspath(): MutableIterable<File>
Gets the classpath associated with the worker. |
|
abstract fun getDisplayName(): String
{@inheritDoc} |
|
abstract fun getForkMode(): ForkMode
Gets the forking mode for this worker, see ForkMode. |
|
abstract fun getForkOptions(): JavaForkOptions
Returns the JavaForkOptions object associated with this builder. |
|
abstract fun getIsolationMode(): IsolationMode
Gets the isolation mode for this worker, see IsolationMode. |
|
abstract fun setClasspath(files: MutableIterable<File>): Unit
Sets the classpath associated with the worker. |
|
abstract fun setDisplayName(displayName: String): Unit
Sets the name to use when displaying this item of work. |
|
abstract fun setForkMode(forkMode: ForkMode): Unit
Sets the forking mode for this worker, see ForkMode. |
|
abstract fun setIsolationMode(isolationMode: IsolationMode): Unit
Sets the isolation mode for this worker, see IsolationMode. |
abstract fun getParams(): Array<Any>
Gets the initialization parameters that will be used when constructing an instance of the implementation class. |
|
abstract fun params(vararg params: Any): Unit
Adds initialization parameters to use when constructing an instance of the implementation class. |
|
abstract fun setParams(vararg params: Any): Unit
Sets any initialization parameters to use when constructing an instance of the implementation class. |