public interface JobGraphWriter extends LocallyCleanableResource, GloballyCleanableResource
Modifier and Type | Method and Description |
---|---|
default CompletableFuture<Void> |
globalCleanupAsync(JobID jobId,
Executor executor)
globalCleanupAsync is expected to be called from the main thread. |
default CompletableFuture<Void> |
localCleanupAsync(JobID jobId,
Executor executor)
localCleanupAsync is expected to be called from the main thread. |
void |
putJobGraph(JobGraph jobGraph)
Adds the
JobGraph instance. |
default CompletableFuture<Void> localCleanupAsync(JobID jobId, Executor executor)
LocallyCleanableResource
localCleanupAsync
is expected to be called from the main thread. Heavy IO tasks
should be outsourced into the passed cleanupExecutor
. Thread-safety must be ensured.localCleanupAsync
in interface LocallyCleanableResource
jobId
- The JobID
of the job for which the local data should be cleaned up.executor
- The fallback executor for IO-heavy operations.default CompletableFuture<Void> globalCleanupAsync(JobID jobId, Executor executor)
GloballyCleanableResource
globalCleanupAsync
is expected to be called from the main thread. Heavy IO tasks
should be outsourced into the passed cleanupExecutor
. Thread-safety must be ensured.globalCleanupAsync
in interface GloballyCleanableResource
jobId
- The JobID
of the job for which the local data should be cleaned up.executor
- The fallback executor for IO-heavy operations.Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.