public class EtcdWatchPollingStrategy extends Object implements PollingStrategy
PollingStrategy.PollingEvent| Constructor and Description |
|---|
EtcdWatchPollingStrategy(EtcdConfigSourceBuilder.EtcdEndpoint endpoint)
Creates polling strategy from etcd params.
|
| Modifier and Type | Method and Description |
|---|---|
static EtcdWatchPollingStrategy |
create(EtcdConfigSourceBuilder.EtcdEndpoint endpoint)
Creates polling strategy from etcd params.
|
Flow.Publisher<PollingStrategy.PollingEvent> |
ticks()
Returns a
Flow.Publisher which fires PollingStrategy.PollingEvents. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetpublic EtcdWatchPollingStrategy(EtcdConfigSourceBuilder.EtcdEndpoint endpoint)
endpoint - etcd remote descriptorpublic static EtcdWatchPollingStrategy create(EtcdConfigSourceBuilder.EtcdEndpoint endpoint)
endpoint - etcd remote descriptorpublic Flow.Publisher<PollingStrategy.PollingEvent> ticks()
PollingStrategyFlow.Publisher which fires PollingStrategy.PollingEvents.
Note that PollingStrategy implementations can generate
PollingEvents whether or not any subscribers have subscribed to
the publisher of the events.
Subscribers typically invoke Flow.Subscription#request(long)
asking for one event initially, and then after it has processed each
event the subscriber requests one more event.
The subscriber might not receive every event broadcast, for example if it subscribes to the publisher after an event has been delivered to the publisher.
Each PollingStrategy implementation chooses which executor to use
for notifying subscribers. The recommended practice is to use the same
thread as the polling strategy implementation runs on.
ticks in interface PollingStrategyCopyright © 2018–2019 Oracle and/or its affiliates. All rights reserved. Use is subject to license terms.