public class MultiClientDistributedSink extends DistributedTransport
Sink instance connecting to each destination. This class interacts
with Sink interface and it does not make any assumptions on the underlying transport implementation.| Modifier and Type | Class and Description |
|---|---|
class |
MultiClientDistributedSink.MultiClientConnectionCallback
Connection callback to notify DistributionStrategy about new connection initiations and failures
|
DistributedTransport.ConnectionCallbackSink.OnErrorActionsiddhiAppContext, strategy, streamDefinitionisTryingToConnect| Constructor and Description |
|---|
MultiClientDistributedSink() |
| Modifier and Type | Method and Description |
|---|---|
void |
connect()
Will be called to connect to the backend before events are published
|
void |
destroy()
Will be called at the end to clean all the resources consumed
|
void |
disconnect()
Will be called after all publishing is done, or when ConnectionUnavailableException is thrown
|
protected ServiceDeploymentInfo |
exposeServiceDeploymentInfo()
Give information to the deployment about the service exposed by the sink.
|
List<ServiceDeploymentInfo> |
getServiceDeploymentInfoList() |
Class[] |
getSupportedInputEventClasses() |
void |
initTransport(OptionHolder sinkOptionHolder,
List<OptionHolder> destinationOptionHolders,
Map<String,String> deploymentProperties,
List<Map<String,String>> destinationDeploymentProperties,
io.siddhi.query.api.annotation.Annotation sinkAnnotation,
ConfigReader sinkConfigReader,
DistributionStrategy strategy,
String type,
SiddhiAppContext siddhiAppContext) |
void |
publish(Object payload,
DynamicOptions transportOptions,
Integer destinationId,
State state) |
getSupportedDynamicOptions, init, init, isConnected, publishconnectWithRetry, getHandler, getMapper, getStreamDefinition, getType, init, initOnlyTransport, isStateful, onError, publish, retryPublish, setConnected, shutdownpublic void publish(Object payload, DynamicOptions transportOptions, Integer destinationId, State state) throws ConnectionUnavailableException
publish in class DistributedTransportConnectionUnavailableExceptionpublic void initTransport(OptionHolder sinkOptionHolder, List<OptionHolder> destinationOptionHolders, Map<String,String> deploymentProperties, List<Map<String,String>> destinationDeploymentProperties, io.siddhi.query.api.annotation.Annotation sinkAnnotation, ConfigReader sinkConfigReader, DistributionStrategy strategy, String type, SiddhiAppContext siddhiAppContext)
initTransport in class DistributedTransportpublic Class[] getSupportedInputEventClasses()
getSupportedInputEventClasses in class Sinkprotected ServiceDeploymentInfo exposeServiceDeploymentInfo()
SinkexposeServiceDeploymentInfo in class Sinkpublic void connect()
throws ConnectionUnavailableException
connect in class SinkConnectionUnavailableException - if it cannot connect to the backendpublic void disconnect()
disconnect in class Sinkpublic void destroy()
public List<ServiceDeploymentInfo> getServiceDeploymentInfoList()
getServiceDeploymentInfoList in class SinkCopyright © 2020. All rights reserved.