accumulo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "shweta.agrawal" <shweta.agra...@orkash.com>
Subject Re: Transaction type query in accumulo
Date Tue, 03 Nov 2015 03:24:01 GMT
Thanks Josh and Keith.
This is exactly what I am looking. I have set some value for row through 
conditional mutation if that exists I am updating the entries of a row. 
So I think in that case conditional mutational will work. It will not be 
interrupted by other threads.

Thanks
Shweta

On Monday 02 November 2015 09:30 PM, Keith Turner wrote:
>
>
> On Fri, Oct 30, 2015 at 7:36 AM, shweta.agrawal 
> <shweta.agrawal@orkash.com <mailto:shweta.agrawal@orkash.com>> wrote:
>
>     Hi,
>
>     Is transaction type facility available in Accumulo?
>     I have read about transaction in accumulo which says " Accumulo
>     guarantees these ACID properties for a single mutation (a set of
>     changes for a single row) but does not provide support for atomic
>     updates across multiple rows"
>
>     In my case:
>     If one thread is updating the fields of a document then this
>     document should be locked so that other thread cannot modify that
>     document.
>
>     I am trying to achieve this by a query through conditional
>     mutation. I am checking whether the particular entry exist or not 
>     then updating. But the problem is I am doing this through 150
>     threads. If one thread finds and updating particular entry then
>     other thread should not get it.
>
>     So is this the case in conditional write?
>
>
> This could be done with a conditional write and a sequence number 
> column per row.
>
> Could do something like the following
>
>   * Read row using isolated scanner or whole row iterator.
>   * Assume row has a column like sync:seq.
>   * Make changes to row in client.
>   * Write conditional mutation with condition that sync:seq is what 
> was read earlier.  Also increment the sequence number
>
> With this pattern only one client can succesfully read-modify-write a 
> row concurrently.  In the case where the column synch:seq does not 
> exist, the conditional mutation should assert it does not exist and 
> set it to an initial value.
>
>
> Is this what you are looking for?  Or are you trying to do something else?
>
>
>     We are achieving same thing through mongoDB by find and modify
>     feature.
>
>     If one thread get particular document to update from conditional
>     write then other thread should get that particular document.
>
>     Please provide your inputs
>
>     Thanks
>     Shweta
>
>


Mime
View raw message