Interface Refresher
-
- All Known Implementing Classes:
AbstractRefresher
,CarrierRefresher
,HttpRefresher
public interface Refresher
ARefresher
keeps bucket configs up to date. The refresher is the companion behavior to the loader. The loader does the initial loading and the refresher does its best to keep theConfigurationProvider
informed with an up-to-date configuration for a bucket.- Since:
- 1.0
- Author:
- Michael Nitschinger
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description rx.Observable<ProposedBucketConfigContext>
configs()
Returns theObservable
which will push out new configuration updates.rx.Observable<Boolean>
deregisterBucket(String name)
De-registers a bucket from watching.void
markTainted(BucketConfig config)
Marks the given bucket as tainted.void
markUntainted(BucketConfig config)
Mark the given bucket as not tainted.void
provider(ConfigurationProvider provider)
void
refresh(ClusterConfig config)
If pull based, refresh configs for registered buckets.rx.Observable<Boolean>
registerBucket(String name, String password)
Deprecated.rx.Observable<Boolean>
registerBucket(String name, String username, String password)
Registers a bucket to be watched for new configurations.rx.Observable<Boolean>
shutdown()
Shuts down all open registration streams.
-
-
-
Method Detail
-
configs
rx.Observable<ProposedBucketConfigContext> configs()
Returns theObservable
which will push out new configuration updates.- Returns:
- the config observable.
-
registerBucket
@Deprecated rx.Observable<Boolean> registerBucket(String name, String password)
Deprecated.Registers a bucket to be watched for new configurations.- Returns:
- true if it succeeded, a failing
Observable
otherwise with the cause.
-
registerBucket
rx.Observable<Boolean> registerBucket(String name, String username, String password)
Registers a bucket to be watched for new configurations.- Returns:
- true if it succeeded, a failing
Observable
otherwise with the cause.
-
deregisterBucket
rx.Observable<Boolean> deregisterBucket(String name)
De-registers a bucket from watching.- Returns:
- true if succeeded, a failing
Observable
otherwise with the cause.
-
shutdown
rx.Observable<Boolean> shutdown()
Shuts down all open registration streams.- Returns:
- true if succeeded, a failing
Observable
otherwise with the cause.
-
markTainted
void markTainted(BucketConfig config)
Marks the given bucket as tainted.- Parameters:
config
- the config of the bucket that should be marked.
-
markUntainted
void markUntainted(BucketConfig config)
Mark the given bucket as not tainted.- Parameters:
config
- the config of the bucket that should not be marked anymore.
-
refresh
void refresh(ClusterConfig config)
If pull based, refresh configs for registered buckets.
-
provider
void provider(ConfigurationProvider provider)
-
-