You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Bart De Neuter <bd...@gmail.com> on 2013/08/29 08:55:47 UTC

Configurable LockType for JpaConsumer

Hi,

We are using the DB as a poor man's queue and we have two instances from our
application running. This means we have competing consumers.
By default the jpa consumer uses LockType.WRITE. Is it possible to configure
this to PESSIMISTIC locking? We call a legacy service which is not IDEM
POTENT causing some bugs in a backend system. Using pessimistic locking
solves this but it looks like we can not configure the jpa component to use
another LockType.

Kind regards,
Bart



--
View this message in context: http://camel.465427.n5.nabble.com/Configurable-LockType-for-JpaConsumer-tp5738192.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Configurable LockType for JpaConsumer

Posted by Bart De Neuter <bd...@gmail.com>.
Hi Claus,

I created a jira ticket and included a patch.




--
View this message in context: http://camel.465427.n5.nabble.com/Configurable-LockType-for-JpaConsumer-tp5738192p5738206.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Configurable LockType for JpaConsumer

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

Ah looks like we can add an option so you can configure this. Feel
free to log a JIRA ticket. And as we love contributions, you are
welcome to work on a patch.
http://camel.apache.org/contributing.html

On Thu, Aug 29, 2013 at 8:55 AM, Bart De Neuter <bd...@gmail.com> wrote:
> Hi,
>
> We are using the DB as a poor man's queue and we have two instances from our
> application running. This means we have competing consumers.
> By default the jpa consumer uses LockType.WRITE. Is it possible to configure
> this to PESSIMISTIC locking? We call a legacy service which is not IDEM
> POTENT causing some bugs in a backend system. Using pessimistic locking
> solves this but it looks like we can not configure the jpa component to use
> another LockType.
>
> Kind regards,
> Bart
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Configurable-LockType-for-JpaConsumer-tp5738192.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen