public class CachingContext extends Object implements Closeable
| Constructor and Description |
|---|
CachingContext(ExperimentsCache cache,
Experiment.BuilderFactory builderFactory) |
CachingContext(ExperimentsCache cache,
Experiment.BuilderFactory builderFactory,
ExecutorService executorService) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
checkIfAnyStale()
Checks whether any experiments are stale
|
boolean |
checkIfStale(String experimentName)
Checks whether a given experiment is stale
|
void |
close() |
void |
delete(String experimentName)
Updates the cache with a recently deleted experiment
|
void |
invalidate(String experimentName,
boolean async)
Forces cache to reload a specific experiment from storage
|
void |
invalidateAll(boolean async)
Forces cache to reload all data from storage
|
void |
update(Experiment experiment)
Updates the cache with a newly loaded experiment
|
public CachingContext(ExperimentsCache cache, Experiment.BuilderFactory builderFactory, ExecutorService executorService)
public CachingContext(ExperimentsCache cache, Experiment.BuilderFactory builderFactory)
public void invalidateAll(boolean async)
public void invalidate(String experimentName, boolean async)
public void update(Experiment experiment)
public void delete(String experimentName)
public boolean checkIfAnyStale()
public boolean checkIfStale(String experimentName)
public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableIOExceptionCopyright © 2020. All rights reserved.