The timer component is used for generating message exchanges when a timer fires. This component is similar to the scheduler component, but has much less functionality.
Name | Kind | Group | Required | Default | Type | Enum | Description |
---|---|---|---|---|---|---|---|
timerName | path | consumer | true | java.lang.String | The name of the timer | ||
bridgeErrorHandler | parameter | consumer | boolean | Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions occurred while the consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions, that will be logged at WARN/ERROR level and ignored. | |||
delay | parameter | consumer | 1000 | long | The number of milliseconds to wait before the first event is generated. Should not be used in conjunction with the time option. The default value is 1000. | ||
fixedRate | parameter | consumer | boolean | Events take place at approximately regular intervals, separated by the specified period. | |||
period | parameter | consumer | 1000 | long | If greater than 0, generate periodic events every period milliseconds. The default value is 1000. | ||
repeatCount | parameter | consumer | 0 | long | Specifies a maximum limit of number of fires. So if you set it to 1, the timer will only fire once. If you set it to 5, it will only fire five times. A value of zero or negative means fire forever. | ||
exceptionHandler | parameter | consumer (advanced) | org.apache.camel.spi.ExceptionHandler | To let the consumer use a custom ExceptionHandler. + Notice if the option bridgeErrorHandler is enabled then this options is not in use. + By default the consumer will deal with exceptions, that will be logged at WARN/ERROR level and ignored. | |||
daemon | parameter | advanced | true | boolean | Specifies whether or not the thread associated with the timer endpoint runs as a daemon. The default value is true. | ||
exchangePattern | parameter | advanced | InOnly | org.apache.camel.ExchangePattern | InOnly RobustInOnly InOut InOptionalOut OutOnly RobustOutOnly OutIn OutOptionalIn |
Sets the default exchange pattern when creating an exchange. | |
pattern | parameter | advanced | java.lang.String | Allows you to specify a custom Date pattern to use for setting the time option using URI syntax. | |||
synchronous | parameter | advanced | false | boolean | Sets whether synchronous processing should be strictly used, or Camel is allowed to use asynchronous processing (if supported). @param synchronous true to enforce synchronous processing | ||
time | parameter | advanced | java.util.Date | A java.util.Date the first event should be generated. If using the URI, the pattern expected is: yyyy-MM-dd HH:mm:ss or yyyy-MM-dd'T'HH:mm:ss. | |||
timer | parameter | advanced | java.util.Timer | To use a custom {@link Timer} |
The timer consumer.