@UriEndpoint(firstVersion="2.24.0",
scheme="jgroups-raft",
title="JGroups raft",
syntax="jgroup-raft:clusterName",
category={CLUSTERING,MESSAGING})
public class JGroupsRaftEndpoint
extends org.apache.camel.support.DefaultEndpoint
| Constructor and Description |
|---|
JGroupsRaftEndpoint(String endpointUri,
String clusterName,
org.apache.camel.Component component,
String remaining,
Map<String,Object> parameters,
String raftId,
String channelProperties,
org.jgroups.protocols.raft.StateMachine stateMachine,
org.jgroups.raft.RaftHandle raftHandle) |
| Modifier and Type | Method and Description |
|---|---|
void |
connect()
Connect shared RaftHandle channel, called by producer and consumer.
|
org.apache.camel.Consumer |
createConsumer(org.apache.camel.Processor processor) |
org.apache.camel.Producer |
createProducer() |
void |
disconnect()
Disconnect shared RaftHandle channel, called by producer and consumer.
|
protected void |
doStart() |
protected void |
doStop() |
String |
getChannelProperties() |
String |
getClusterName() |
org.jgroups.raft.RaftHandle |
getRaftHandle() |
String |
getRaftId() |
org.jgroups.raft.RaftHandle |
getResolvedRaftHandle() |
org.jgroups.protocols.raft.StateMachine |
getStateMachine() |
boolean |
isEnableRoleChangeEvents() |
void |
populateJGroupsRaftHeaders(org.apache.camel.Exchange exchange) |
void |
setChannelProperties(String channelProperties) |
void |
setClusterName(String clusterName)
The name of the JGroupsraft cluster the component should connect to.
|
void |
setEnableRoleChangeEvents(boolean enableRoleChangeEvents)
If set to true, the consumer endpoint will receive roleChange event as well (not just connecting and/or using the
state machine).
|
void |
setRaftHandle(org.jgroups.raft.RaftHandle raftHandle) |
void |
setRaftId(String raftId) |
void |
setStateMachine(org.jgroups.protocols.raft.StateMachine stateMachine) |
configureConsumer, configureExchange, configurePollingConsumer, configureProperties, createAsyncProducer, createEndpointUri, createExchange, createExchange, createPollingConsumer, doInit, equals, getCamelContext, getComponent, getEndpointKey, getEndpointUri, getExceptionHandler, getExchangePattern, getId, getPollingConsumerBlockTimeout, getPollingConsumerQueueSize, hashCode, isAutowiredEnabled, isBridgeErrorHandler, isLazyStartProducer, isLenientProperties, isPollingConsumerBlockWhenFull, isPollingConsumerCopy, isSingleton, setAutowiredEnabled, setBridgeErrorHandler, setCamelContext, setComponent, setEndpointUri, setEndpointUriIfNotSpecified, setExceptionHandler, setExchangePattern, setLazyStartProducer, setPollingConsumerBlockTimeout, setPollingConsumerBlockWhenFull, setPollingConsumerCopy, setPollingConsumerQueueSize, setProperties, toStringbuild, doBuild, doFail, doLifecycleChange, doResume, doShutdown, doSuspend, fail, getStatus, init, isBuild, isInit, isNew, isRunAllowed, isShutdown, isStarted, isStarting, isStartingOrStarted, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, isSuspendingOrSuspended, resume, shutdown, start, stop, suspendclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic JGroupsRaftEndpoint(String endpointUri, String clusterName, org.apache.camel.Component component, String remaining, Map<String,Object> parameters, String raftId, String channelProperties, org.jgroups.protocols.raft.StateMachine stateMachine, org.jgroups.raft.RaftHandle raftHandle)
public org.apache.camel.Consumer createConsumer(org.apache.camel.Processor processor)
throws Exception
Exceptionpublic void populateJGroupsRaftHeaders(org.apache.camel.Exchange exchange)
protected void doStart()
throws Exception
doStart in class org.apache.camel.support.DefaultEndpointExceptionprotected void doStop()
throws Exception
doStop in class org.apache.camel.support.DefaultEndpointExceptionpublic void connect()
throws Exception
Exceptionpublic void disconnect()
public String getClusterName()
public void setClusterName(String clusterName)
public boolean isEnableRoleChangeEvents()
public void setEnableRoleChangeEvents(boolean enableRoleChangeEvents)
public String getChannelProperties()
public void setChannelProperties(String channelProperties)
public String getRaftId()
public void setRaftId(String raftId)
public org.jgroups.raft.RaftHandle getRaftHandle()
public void setRaftHandle(org.jgroups.raft.RaftHandle raftHandle)
public org.jgroups.protocols.raft.StateMachine getStateMachine()
public void setStateMachine(org.jgroups.protocols.raft.StateMachine stateMachine)
public org.jgroups.raft.RaftHandle getResolvedRaftHandle()
Apache Camel