Hi Yeah that is a mistake in the javadoc. I have corrected that for upcoming releases.
For eager mode, its add and confirm that are called. For non-eager mode its contains and add that are called. .. and if the message failed, then its remove that are called instead of confirm/add. On Thu, Feb 20, 2014 at 9:18 AM, fs <[email protected]> wrote: > Created a custom IdempotentRepository implementation that uses MongoDB for > storing idempotent keys. It implements the > org.apache.camel.spi.IdempotentRepository interface. > > Noticed that the contains method is not called when setting the eager option > to true. It seems to be the opposite to the javadoc comment. > > /** > * Returns <tt>true</tt> if this repository contains the specified > element. > * <p/> > * This operation is used if the option <tt>eager</tt> has been enabled. > * > * @param key the key of the message > * @return <tt>true</tt> if this repository contains the specified > element > */ > boolean contains(E key); > > Any ideas why this is happening? > > Trying to get the Filter duplicate messages thing to work: > http://camel.apache.org/idempotent-consumer.html (How to handle duplicate > messages in the route) > > Using ServiceMix 4.5.3 and Camel 2.10.7 > > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/IdempotentConsumer-contains-not-called-tp5747630.html > Sent from the Camel - Users mailing list archive at Nabble.com. -- Claus Ibsen ----------------- Red Hat, Inc. Email: [email protected] Twitter: davsclaus Blog: http://davsclaus.com Author of Camel in Action: http://www.manning.com/ibsen Make your Camel applications look hawt, try: http://hawt.io
