Package org.apache.storm.scheduler.utils
Class SchedulerConfigCache<T>
java.lang.Object
org.apache.storm.scheduler.utils.SchedulerConfigCache<T>
A utility class to cache the scheduler config and refresh after the cache expires.
- 
Nested Class SummaryNested Classes
- 
Constructor SummaryConstructorsConstructorDescriptionSchedulerConfigCache(Map<String, Object> conf, SchedulerConfigCache.Reloadable<T> reloader) 
- 
Method Summary
- 
Constructor Details- 
SchedulerConfigCache
 
- 
- 
Method Details- 
preparepublic void prepare()
- 
refreshpublic void refresh()Refresh the config only after the cache expires. This is not thread-safe and should only be called in single thread.
- 
getGet the scheduler config from cache. This method is thead-safe and can be called in multiple threads.- Returns:
- the scheduler config
 
 
-