@Metadata(label="eip,routing") public class PollEnrichDefinition extends ExpressionNode
Enricher
inheritErrorHandler, log
Constructor and Description |
---|
PollEnrichDefinition() |
PollEnrichDefinition(org.apache.camel.AggregationStrategy aggregationStrategy,
long timeout) |
Modifier and Type | Method and Description |
---|---|
PollEnrichDefinition |
aggregateOnException(boolean aggregateOnException)
If this option is false then the aggregate method is not used if there was an exception thrown while trying to
retrieve the data to enrich from the resource.
|
PollEnrichDefinition |
aggregationStrategy(org.apache.camel.AggregationStrategy aggregationStrategy)
Sets the AggregationStrategy to be used to merge the reply from the external service, into a single outgoing
message.
|
PollEnrichDefinition |
aggregationStrategy(Supplier<org.apache.camel.AggregationStrategy> aggregationStrategy)
Sets the AggregationStrategy to be used to merge the reply from the external service, into a single outgoing
message.
|
PollEnrichDefinition |
aggregationStrategyMethodAllowNull(boolean aggregationStrategyMethodAllowNull)
If this option is false then the aggregate method is not used if there was no data to enrich.
|
PollEnrichDefinition |
aggregationStrategyMethodName(String aggregationStrategyMethodName)
This option can be used to explicit declare the method name to use, when using POJOs as the AggregationStrategy.
|
PollEnrichDefinition |
aggregationStrategyRef(String aggregationStrategyRef)
Refers to an AggregationStrategy to be used to merge the reply from the external service, into a single outgoing
message.
|
PollEnrichDefinition |
cacheSize(int cacheSize)
Sets the maximum size used by the
ConsumerCache which is used to cache and reuse
consumers when uris are reused. |
PollEnrichDefinition |
cacheSize(String cacheSize)
Sets the maximum size used by the
ConsumerCache which is used to cache and reuse
consumers when uris are reused. |
String |
getAggregateOnException() |
org.apache.camel.AggregationStrategy |
getAggregationStrategy() |
String |
getAggregationStrategyMethodAllowNull() |
String |
getAggregationStrategyMethodName() |
String |
getAggregationStrategyRef() |
String |
getCacheSize() |
String |
getIgnoreInvalidEndpoint() |
String |
getLabel()
Returns a label to describe this node such as the expression if some kind of expression node
|
String |
getShortName() |
String |
getTimeout() |
PollEnrichDefinition |
ignoreInvalidEndpoint()
Ignore the invalidate endpoint exception when try to create a producer with that endpoint
|
void |
setAggregateOnException(String aggregateOnException) |
void |
setAggregationStrategy(org.apache.camel.AggregationStrategy aggregationStrategy) |
void |
setAggregationStrategyMethodAllowNull(String aggregationStrategyMethodAllowNull) |
void |
setAggregationStrategyMethodName(String aggregationStrategyMethodName) |
void |
setAggregationStrategyRef(String aggregationStrategyRef) |
void |
setCacheSize(String cacheSize) |
void |
setExpression(ExpressionDefinition expression)
Expression that computes the endpoint uri to use as the resource endpoint to enrich from
|
void |
setIgnoreInvalidEndpoint(String ignoreInvalidEndpoint) |
void |
setTimeout(String timeout) |
PollEnrichDefinition |
timeout(long timeout)
Timeout in millis when polling from the external service.
|
String |
toString() |
configureChild, getExpression, getExpressionType, getOutputs, id, preCreateProcessor, setExpression, setExpressionType
addInterceptStrategy, addOutput, aggregate, aggregate, aggregate, aggregate, bean, bean, bean, bean, bean, bean, bean, bean, bean, bean, bean, choice, circuitBreaker, claimCheck, claimCheck, claimCheck, claimCheck, clearOutput, convertBodyTo, convertBodyTo, convertBodyTo, delay, delay, delay, doTry, dynamicRouter, dynamicRouter, end, endChoice, endCircuitBreaker, endDoTry, endParent, endRest, enrich, enrich, enrich, enrich, enrich, enrich, enrich, enrich, enrich, enrichWith, enrichWith, enrichWith, enrichWith, enrichWith, enrichWith, filter, filter, filter, filter, getIndex, getInterceptStrategies, getParent, idempotentConsumer, idempotentConsumer, idempotentConsumer, inheritErrorHandler, inOnly, inOnly, inOnly, inOnly, inOnly, inOut, inOut, inOut, inOut, inOut, isAbstract, isInheritErrorHandler, isTopLevelOnly, isWrappingEntireOutput, kamelet, loadBalance, loadBalance, log, log, log, log, log, log, loop, loop, loop, loopDoWhile, loopDoWhile, markRollbackOnly, markRollbackOnlyLast, marshal, marshal, marshal, marshal, multicast, multicast, multicast, onCompletion, onException, onException, pipeline, pipeline, pipeline, pipeline, policy, policy, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrich, pollEnrichWith, pollEnrichWith, pollEnrichWith, pollEnrichWith, pollEnrichWith, pollEnrichWith, process, process, process, recipientList, recipientList, recipientList, recipientList, removeHeader, removeHeaders, removeHeaders, removeProperties, removeProperties, removeProperty, resequence, resequence, rollback, rollback, routeDescription, routeGroup, routeId, routingSlip, routingSlip, routingSlip, saga, sample, sample, sample, sample, script, script, serviceCall, serviceCall, serviceCall, setBody, setBody, setBody, setExchangePattern, setHeader, setHeader, setHeader, setInheritErrorHandler, setParent, setProperty, setProperty, setProperty, sort, sort, sort, split, split, split, split, startupOrder, step, step, stop, threads, threads, threads, threads, throttle, throttle, throttle, throttle, throttle, throwException, throwException, to, to, to, to, to, to, to, to, to, to, to, to, to, to, toD, toD, toD, toD, toD, toD, toD, toF, transacted, transacted, transform, transform, unmarshal, unmarshal, unmarshal, unmarshal, validate, validate, validate, wireTap, wireTap, wireTap
description, description, getCustomId, getDescription, getDescriptionText, getId, hasCustomIdAssigned, idOrCreate, setCustomId, setDescription, setGeneratedId, setId
public PollEnrichDefinition()
public PollEnrichDefinition(org.apache.camel.AggregationStrategy aggregationStrategy, long timeout)
public String getShortName()
public String getLabel()
ProcessorDefinition
getLabel
in interface org.apache.camel.NamedNode
getLabel
in class ExpressionNode
public PollEnrichDefinition timeout(long timeout)
public PollEnrichDefinition aggregationStrategy(org.apache.camel.AggregationStrategy aggregationStrategy)
public PollEnrichDefinition aggregationStrategy(Supplier<org.apache.camel.AggregationStrategy> aggregationStrategy)
public PollEnrichDefinition aggregationStrategyRef(String aggregationStrategyRef)
public PollEnrichDefinition aggregationStrategyMethodName(String aggregationStrategyMethodName)
public PollEnrichDefinition aggregationStrategyMethodAllowNull(boolean aggregationStrategyMethodAllowNull)
public PollEnrichDefinition aggregateOnException(boolean aggregateOnException)
public PollEnrichDefinition cacheSize(int cacheSize)
ConsumerCache
which is used to cache and reuse
consumers when uris are reused.
Beware that when using dynamic endpoints then it affects how well the cache can be utilized. If each dynamic
endpoint is unique then its best to turn of caching by setting this to -1, which allows Camel to not cache both
the producers and endpoints; they are regarded as prototype scoped and will be stopped and discarded after use.
This reduces memory usage as otherwise producers/endpoints are stored in memory in the caches.
However if there are a high degree of dynamic endpoints that have been used before, then it can benefit to use
the cache to reuse both producers and endpoints and therefore the cache size can be set accordingly or rely on
the default size (1000).
If there is a mix of unique and used before dynamic endpoints, then setting a reasonable cache size can help
reduce memory usage to avoid storing too many non frequent used producers.cacheSize
- the cache size, use 0 for default cache size, or -1 to turn cache off.public PollEnrichDefinition cacheSize(String cacheSize)
ConsumerCache
which is used to cache and reuse
consumers when uris are reused.
Beware that when using dynamic endpoints then it affects how well the cache can be utilized. If each dynamic
endpoint is unique then its best to turn of caching by setting this to -1, which allows Camel to not cache both
the producers and endpoints; they are regarded as prototype scoped and will be stopped and discarded after use.
This reduces memory usage as otherwise producers/endpoints are stored in memory in the caches.
However if there are a high degree of dynamic endpoints that have been used before, then it can benefit to use
the cache to reuse both producers and endpoints and therefore the cache size can be set accordingly or rely on
the default size (1000).
If there is a mix of unique and used before dynamic endpoints, then setting a reasonable cache size can help
reduce memory usage to avoid storing too many non frequent used producers.cacheSize
- the cache size, use 0 for default cache size, or -1 to turn cache off.public PollEnrichDefinition ignoreInvalidEndpoint()
public void setExpression(ExpressionDefinition expression)
setExpression
in class ExpressionNode
public String getTimeout()
public void setTimeout(String timeout)
public String getAggregationStrategyRef()
public void setAggregationStrategyRef(String aggregationStrategyRef)
public String getAggregationStrategyMethodName()
public void setAggregationStrategyMethodName(String aggregationStrategyMethodName)
public String getAggregationStrategyMethodAllowNull()
public void setAggregationStrategyMethodAllowNull(String aggregationStrategyMethodAllowNull)
public org.apache.camel.AggregationStrategy getAggregationStrategy()
public void setAggregationStrategy(org.apache.camel.AggregationStrategy aggregationStrategy)
public String getAggregateOnException()
public void setAggregateOnException(String aggregateOnException)
public String getCacheSize()
public void setCacheSize(String cacheSize)
public String getIgnoreInvalidEndpoint()
public void setIgnoreInvalidEndpoint(String ignoreInvalidEndpoint)
Apache Camel