Class DefaultExecutionGraphCache
- java.lang.Object
-
- org.apache.flink.runtime.rest.handler.legacy.DefaultExecutionGraphCache
-
- All Implemented Interfaces:
Closeable,AutoCloseable,ExecutionGraphCache
public class DefaultExecutionGraphCache extends Object implements ExecutionGraphCache
Default implementation ofExecutionGraphCache.
-
-
Constructor Summary
Constructors Constructor Description DefaultExecutionGraphCache(Duration timeout, Duration timeToLive)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcleanup()Perform the cleanup of out dated cache entries.voidclose()Closes the execution graph cache.CompletableFuture<ExecutionGraphInfo>getExecutionGraphInfo(org.apache.flink.api.common.JobID jobId, RestfulGateway restfulGateway)Gets theExecutionGraphInfofor the givenJobIDand caches it.intsize()Gets the number of cache entries.
-
-
-
Method Detail
-
close
public void close()
Description copied from interface:ExecutionGraphCacheCloses the execution graph cache.- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Specified by:
closein interfaceExecutionGraphCache
-
size
public int size()
Description copied from interface:ExecutionGraphCacheGets the number of cache entries.- Specified by:
sizein interfaceExecutionGraphCache
-
getExecutionGraphInfo
public CompletableFuture<ExecutionGraphInfo> getExecutionGraphInfo(org.apache.flink.api.common.JobID jobId, RestfulGateway restfulGateway)
Description copied from interface:ExecutionGraphCacheGets theExecutionGraphInfofor the givenJobIDand caches it. TheExecutionGraphInfowill be requested again after the refresh interval has passed or if the graph could not be retrieved from the given gateway.- Specified by:
getExecutionGraphInfoin interfaceExecutionGraphCache- Parameters:
jobId- identifying theExecutionGraphInfoto getrestfulGateway- to request theExecutionGraphInfofrom- Returns:
- Future containing the requested
ExecutionGraphInfo
-
cleanup
public void cleanup()
Description copied from interface:ExecutionGraphCachePerform the cleanup of out dated cache entries.- Specified by:
cleanupin interfaceExecutionGraphCache
-
-