Module: vertx-service-discovery-js/event_bus_service

Classes

EventBusService

Methods

(static) EventBusService.createRecord(name, address, classname) → {Object}

Creates a record based on the parameters.
Parameters:
Name Type Description
name string the service name
address string the address
classname string the payload class
Source:
Returns:
the record
Type
Object

(static) EventBusService.getServiceProxy(discovery, filter, clientClass, resultHandler) → {Object}

Lookup for a service record and if found, retrieve it and return the service object (used to consume the service). This is a convenient method to avoid explicit lookup and then retrieval of the service. This method requires to have the clientClass set with the expected set of client. This is important for usages not using Java so you can pass the expected type.
Parameters:
Name Type Description
discovery ServiceDiscovery the service discovery
filter function the filter
clientClass todo the client class
resultHandler function the result handler
Source:
Returns:
null - do not use
Type
Object

(static) EventBusService.getServiceProxyWithJsonFilter(discovery, filter, clientClass, resultHandler) → {Object}

Lookup for a service record and if found, retrieve it and return the service object (used to consume the service). This is a convenient method to avoid explicit lookup and then retrieval of the service. This method requires to have the clientClass set with the expected set of client. This is important for usages not using Java so you can pass the expected type.
Parameters:
Name Type Description
discovery ServiceDiscovery the service discovery
filter Object the filter as json object
clientClass todo the client class
resultHandler function the result handler
Source:
Returns:
null - do not use
Type
Object