You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by stefzar <st...@hotmail.com> on 2012/06/18 19:42:38 UTC
How to set the LRU-Cache size?
Hello,
in the Camel documentation it says: "idempotent false Option to use the
Idempotent Consumer EIP pattern to let Camel skip already processed files.
Will by default use a memory based LRUCache that holds 1000 entries. If
noop=true then idempotent will be enabled as well to avoid consuming the
same files over and over again." - http://camel.apache.org/file2.html
What's the easiest way of setting the LRUCache size above 1000 entries?
Thank you in advance.
--
View this message in context: http://camel.465427.n5.nabble.com/How-to-set-the-LRU-Cache-size-tp5714634.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Re: How to set the LRU-Cache size?
Posted by stefzar <st...@hotmail.com>.
Thank you, I've done it by extending MemoryIdempotentRepository and
initialized the superconstructor with a HashMap instance. This way the size
stays variable, because the setCacheSize method does only work at the
beginning, when the LRU-Cache was not already initialized.
--
View this message in context: http://camel.465427.n5.nabble.com/How-to-set-the-LRU-Cache-size-tp5714634p5714677.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Re: How to set the LRU-Cache size?
Posted by Claus Ibsen <cl...@gmail.com>.
On Mon, Jun 18, 2012 at 7:42 PM, stefzar <st...@hotmail.com> wrote:
> Hello,
>
> in the Camel documentation it says: "idempotent false Option to use the
> Idempotent Consumer EIP pattern to let Camel skip already processed files.
> Will by default use a memory based LRUCache that holds 1000 entries. If
> noop=true then idempotent will be enabled as well to avoid consuming the
> same files over and over again." - http://camel.apache.org/file2.html
>
> What's the easiest way of setting the LRUCache size above 1000 entries?
>
>
To set a custom idempotentRepository
And have that using a memory store, where you can configure the size.
Thank you in advance.
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/How-to-set-the-LRU-Cache-size-tp5714634.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>
--
Claus Ibsen
-----------------
FuseSource
Email: cibsen@fusesource.com
Web: http://fusesource.com
Twitter: davsclaus, fusenews
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen