Read Before Writes on Distributed Counters

Jeremiah Peschka jeremiah.peschka at gmail.com
Thu Oct 17 11:46:42 EDT 2013


That's why I linked to the video - it's 60 minutes of Cribbs™ brand
pedantry.

---
Jeremiah Peschka - Founder, Brent Ozar Unlimited
MCITP: SQL Server 2008, MVP
Cloudera Certified Developer for Apache Hadoop


On Thu, Oct 17, 2013 at 10:45 AM, Sean Cribbs <sean at basho.com> wrote:

> Since Jeremiah loves it when I'm pedantic, it bears mentioning that the
> list of operations are rolled up immediately (not kept around), grouping by
> which partition took the increment. So if I increment by 2 and then by 50,
> and the increment goes to different replicas, my counter will look like
> [{a, 2}, {b, 50}], for a sum of 52.
>
>
> On Thu, Oct 17, 2013 at 4:21 PM, Jeremiah Peschka <
> jeremiah.peschka at gmail.com> wrote:
>
>> When you 'update' a counter, you send in an increment operation. That's
>> added to an internal list in Riak. The operations are then zipped up to
>> provide the correct counter value on read. The worst that you'll do is add
>> a large(ish) number of values to the op list inside Riak.
>>
>> Siblings will be created, but they will not be visible to the end user
>> who is reading from the counter.
>>
>> Check out this demo of the new counter types from Sean Cribbs:
>> https://vimeo.com/43903960
>>
>> ---
>> Jeremiah Peschka - Founder, Brent Ozar Unlimited
>> MCITP: SQL Server 2008, MVP
>> Cloudera Certified Developer for Apache Hadoop
>>
>>
>> On Thu, Oct 17, 2013 at 9:55 AM, Daniil Churikov <ddosia at gmail.com>wrote:
>>
>>> Correct me if I wrong, but when you blindly do update without previous
>>> read,
>>> you create a sibling, which should be resolved on read. In case if you
>>> make
>>> a lot of increments for counter and rarely reads it will lead to siblings
>>> explosion.
>>>
>>> I am not familiar with new counters datatypes, so I am curious.
>>>
>>>
>>>
>>> --
>>> View this message in context:
>>> http://riak-users.197444.n3.nabble.com/Read-Before-Writes-on-Distributed-Counters-tp4029492p4029498.html
>>> Sent from the Riak Users mailing list archive at Nabble.com.
>>>
>>> _______________________________________________
>>> riak-users mailing list
>>> riak-users at lists.basho.com
>>> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
>>>
>>
>>
>> _______________________________________________
>> riak-users mailing list
>> riak-users at lists.basho.com
>> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
>>
>>
>
>
> --
> Sean Cribbs <sean at basho.com>
> Software Engineer
> Basho Technologies, Inc.
> http://basho.com/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.basho.com/pipermail/riak-users_lists.basho.com/attachments/20131017/71c065d2/attachment.html>


More information about the riak-users mailing list