Class ZookeeperServiceImporter
- java.lang.Object
-
- io.vertx.servicediscovery.zookeeper.ZookeeperServiceImporter
-
- All Implemented Interfaces:
ServiceImporter
,org.apache.curator.framework.recipes.cache.TreeCacheListener
public class ZookeeperServiceImporter extends Object implements ServiceImporter, org.apache.curator.framework.recipes.cache.TreeCacheListener
A service importer retrieving services from Zookeeper.- Author:
- Clement Escoffier
-
-
Constructor Summary
Constructors Constructor Description ZookeeperServiceImporter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
childEvent(org.apache.curator.framework.CuratorFramework curatorFramework, org.apache.curator.framework.recipes.cache.TreeCacheEvent treeCacheEvent)
void
close(Handler<Void> closeHandler)
Closes the importervoid
start(Vertx vertx, ServicePublisher publisher, JsonObject configuration, Promise<Void> future)
Starts the importer.
-
-
-
Method Detail
-
start
public void start(Vertx vertx, ServicePublisher publisher, JsonObject configuration, Promise<Void> future)
Description copied from interface:ServiceImporter
Starts the importer.- Specified by:
start
in interfaceServiceImporter
- Parameters:
vertx
- the vertx instancepublisher
- the service publisher instanceconfiguration
- the bridge configuration if anyfuture
- a future on which the bridge must report the completion of the starting
-
close
public void close(Handler<Void> closeHandler)
Description copied from interface:ServiceImporter
Closes the importer- Specified by:
close
in interfaceServiceImporter
- Parameters:
closeHandler
- the handle to be notified when importer is closed, may benull
-
childEvent
public void childEvent(org.apache.curator.framework.CuratorFramework curatorFramework, org.apache.curator.framework.recipes.cache.TreeCacheEvent treeCacheEvent)
- Specified by:
childEvent
in interfaceorg.apache.curator.framework.recipes.cache.TreeCacheListener
-
-