@Component(value="seda")
public class SedaComponent
extends org.apache.camel.support.DefaultComponent
BlockingQueue within a CamelContext| Modifier and Type | Field and Description |
|---|---|
protected int |
concurrentConsumers |
protected BlockingQueueFactory<org.apache.camel.Exchange> |
defaultQueueFactory |
protected org.slf4j.Logger |
log |
protected int |
maxConcurrentConsumers |
protected int |
queueSize |
| Constructor and Description |
|---|
SedaComponent() |
| Modifier and Type | Method and Description |
|---|---|
protected SedaEndpoint |
createEndpoint(String endpointUri,
org.apache.camel.Component component,
BlockingQueue<org.apache.camel.Exchange> queue,
int concurrentConsumers) |
protected SedaEndpoint |
createEndpoint(String endpointUri,
org.apache.camel.Component component,
BlockingQueueFactory<org.apache.camel.Exchange> queueFactory,
int concurrentConsumers) |
protected org.apache.camel.Endpoint |
createEndpoint(String uri,
String remaining,
Map<String,Object> parameters) |
protected void |
doStop() |
int |
getConcurrentConsumers() |
long |
getDefaultOfferTimeout() |
int |
getDefaultPollTimeout() |
BlockingQueueFactory<org.apache.camel.Exchange> |
getDefaultQueueFactory() |
QueueReference |
getOrCreateQueue(SedaEndpoint endpoint,
Integer size,
Boolean multipleConsumers,
BlockingQueueFactory<org.apache.camel.Exchange> customQueueFactory) |
String |
getQueueKey(String uri) |
QueueReference |
getQueueReference(String key) |
Map<String,QueueReference> |
getQueues() |
int |
getQueueSize() |
boolean |
isDefaultBlockWhenFull() |
boolean |
isDefaultDiscardWhenFull()
Whether a thread that sends messages to a full SEDA queue will be discarded.
|
QueueReference |
registerQueue(SedaEndpoint endpoint,
BlockingQueue<org.apache.camel.Exchange> queue) |
void |
setConcurrentConsumers(int size)
Sets the default number of concurrent threads processing exchanges.
|
void |
setDefaultBlockWhenFull(boolean defaultBlockWhenFull)
Whether a thread that sends messages to a full SEDA queue will block until the queue's capacity is no longer
exhausted.
|
void |
setDefaultDiscardWhenFull(boolean defaultDiscardWhenFull) |
void |
setDefaultOfferTimeout(long defaultOfferTimeout)
Whether a thread that sends messages to a full SEDA queue will block until the queue's capacity is no longer
exhausted.
|
void |
setDefaultPollTimeout(int defaultPollTimeout)
The timeout (in milliseconds) used when polling.
|
void |
setDefaultQueueFactory(BlockingQueueFactory<org.apache.camel.Exchange> defaultQueueFactory)
Sets the default queue factory.
|
void |
setQueueSize(int size)
Sets the default maximum capacity of the SEDA queue (i.e., the number of messages it can hold).
|
afterConfiguration, createEndpoint, createEndpoint, doBuild, doInit, doStart, getAndRemoveOrResolveReferenceParameter, getAndRemoveOrResolveReferenceParameter, getAndRemoveParameter, getAndRemoveParameter, getCamelContext, getComponentPropertyConfigurer, getDefaultName, getEndpointPropertyConfigurer, getExtension, getSupportedExtensions, ifStartsWithReturnRemainder, isAutowiredEnabled, isBridgeErrorHandler, isLazyStartProducer, registerExtension, registerExtension, resolveAndRemoveReferenceListParameter, resolveAndRemoveReferenceListParameter, resolveAndRemoveReferenceParameter, resolveAndRemoveReferenceParameter, resolveRawParameterValues, setAutowiredEnabled, setBridgeErrorHandler, setCamelContext, setLazyStartProducer, setProperties, setProperties, setProperties, useIntrospectionOnEndpoint, useRawUri, validateParameters, validateURIbuild, 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, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitprotected final org.slf4j.Logger log
protected final int maxConcurrentConsumers
@Metadata(label="consumer",
defaultValue="1")
protected int concurrentConsumers
@Metadata(label="advanced",
defaultValue="1000")
protected int queueSize
@Metadata(label="advanced") protected BlockingQueueFactory<org.apache.camel.Exchange> defaultQueueFactory
public void setQueueSize(int size)
public int getQueueSize()
public void setConcurrentConsumers(int size)
public int getConcurrentConsumers()
public BlockingQueueFactory<org.apache.camel.Exchange> getDefaultQueueFactory()
public void setDefaultQueueFactory(BlockingQueueFactory<org.apache.camel.Exchange> defaultQueueFactory)
public boolean isDefaultBlockWhenFull()
public void setDefaultBlockWhenFull(boolean defaultBlockWhenFull)
public boolean isDefaultDiscardWhenFull()
public void setDefaultDiscardWhenFull(boolean defaultDiscardWhenFull)
public long getDefaultOfferTimeout()
public void setDefaultOfferTimeout(long defaultOfferTimeout)
public int getDefaultPollTimeout()
public void setDefaultPollTimeout(int defaultPollTimeout)
public QueueReference getOrCreateQueue(SedaEndpoint endpoint, Integer size, Boolean multipleConsumers, BlockingQueueFactory<org.apache.camel.Exchange> customQueueFactory)
public QueueReference registerQueue(SedaEndpoint endpoint, BlockingQueue<org.apache.camel.Exchange> queue)
public Map<String,QueueReference> getQueues()
public QueueReference getQueueReference(String key)
protected org.apache.camel.Endpoint createEndpoint(String uri, String remaining, Map<String,Object> parameters) throws Exception
createEndpoint in class org.apache.camel.support.DefaultComponentExceptionprotected SedaEndpoint createEndpoint(String endpointUri, org.apache.camel.Component component, BlockingQueueFactory<org.apache.camel.Exchange> queueFactory, int concurrentConsumers)
protected SedaEndpoint createEndpoint(String endpointUri, org.apache.camel.Component component, BlockingQueue<org.apache.camel.Exchange> queue, int concurrentConsumers)
Apache Camel