Interface Refresher
- All Known Implementing Classes:
AbstractRefresher
,CarrierRefresher
,HttpRefresher
public interface Refresher
A
Refresher
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 the ConfigurationProvider
informed with an up-to-date configuration for a bucket.- Since:
- 1.0
- Author:
- Michael Nitschinger
-
Method Summary
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 Details
-
configs
rx.Observable<ProposedBucketConfigContext> configs()Returns theObservable
which will push out new configuration updates.- Returns:
- the config observable.
-
registerBucket
Deprecated.Registers a bucket to be watched for new configurations.- Returns:
- true if it succeeded, a failing
Observable
otherwise with the cause.
-
registerBucket
Registers a bucket to be watched for new configurations.- Returns:
- true if it succeeded, a failing
Observable
otherwise with the cause.
-
deregisterBucket
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
Marks the given bucket as tainted.- Parameters:
config
- the config of the bucket that should be marked.
-
markUntainted
Mark the given bucket as not tainted.- Parameters:
config
- the config of the bucket that should not be marked anymore.
-
refresh
If pull based, refresh configs for registered buckets. -
provider
-