Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Applying eventually consistent on Voldemort
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  5 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
anderson guo  
View profile  
 More options Jan 20 2010, 7:08 am
From: anderson guo <anderson.guowen...@gmail.com>
Date: Wed, 20 Jan 2010 04:08:22 -0800 (PST)
Local: Wed, Jan 20 2010 7:08 am
Subject: Applying eventually consistent on Voldemort
Hi, all

As I know, Voldemort is a reference implementation of Amazon Dynamo,
which emphasize the eventually consistent. However, If I'd like to use
Voldemort as the Shopping Cart or Goods ordering system, How could I
ensure the consistency even there are multiple access towards the
share data, like quantity in store and cart items in shopping carts?

BR/anderson


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Geir Magnusson Jr.  
View profile  
 More options Jan 20 2010, 7:11 am
From: "Geir Magnusson Jr." <g...@pobox.com>
Date: Wed, 20 Jan 2010 07:11:30 -0500
Local: Wed, Jan 20 2010 7:11 am
Subject: Re: [project-voldemort] Applying eventually consistent on Voldemort

On Jan 20, 2010, at 7:08 AM, anderson guo wrote:

> Hi, all

> As I know, Voldemort is a reference implementation of Amazon Dynamo,

Well, it's not really a "reference implementation" in the spec sense.  It's just an implementation.

> which emphasize the eventually consistent. However, If I'd like to use
> Voldemort as the Shopping Cart or Goods ordering system, How could I
> ensure the consistency even there are multiple access towards the
> share data, like quantity in store and cart items in shopping carts?

I use it for shopping cart and handling order processing.  We carefully designed as well as we could around the consistency issue, but it does actually come up from time to time.  You just have to either build around it and accept the limits, or choose another solution.

One solution, which we're considering for a related use, is some kind of 'lock management' that is used along side V, but right now we're still in the handwaving/whiteboard phase...

geir


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
anderson guo  
View profile  
 More options Jan 21 2010, 2:26 am
From: anderson guo <anderson.guowen...@gmail.com>
Date: Wed, 20 Jan 2010 23:26:27 -0800 (PST)
Local: Thurs, Jan 21 2010 2:26 am
Subject: Re: Applying eventually consistent on Voldemort
Hi, Geir

First of all, Thanks for you quick reply.

Second, I don't fully understand what you mean lock management
technology. One mind I learned from Amazon Dynamo paper is make read /
write operation always available, hence lock is evil. Why you
introduce lock in V?

At last, could you give a little hint on what you said carefully
designed for shopping cart and order processing? I think pseudocode is
enough for me to understanding.

BR/anderson

On Jan 20, 8:11 pm, "Geir Magnusson Jr." <g...@pobox.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Dan Ostrowski  
View profile  
 More options Nov 5 2012, 11:42 am
From: Dan Ostrowski <dan.ostrow...@gmail.com>
Date: Mon, 5 Nov 2012 08:42:21 -0800 (PST)
Local: Mon, Nov 5 2012 11:42 am
Subject: Re: Applying eventually consistent on Voldemort

Saying "lock is evil" is nonsense. What you're asking for is your partition
tolerant, available data store to be consistent, so that you can do the
transactional behavior of selling a product, but according to CAP theorem,
that's not possible.

geir, above, is suggesting you lock your resource (such as a product list),
briefly, using either, I would imagine, Redis or Zookeeper so that you can
be assured you don't oversell. However, this doesn't work, in reality.
(An acquaintance of mine wrote about this here:
http://aphyr.com/posts/254-burn-the-library).

Amazon has this very problem and, famously, their solution is "coupons!"
They just give coupons out whenever their shopping cart system screws up,
or that's how they solved it for a while. The solution may be to simply
move product management OUT of your Dynamo storage and into something less
available, but more consistent like Redis or even a regular DB. Depending
on the focus of your site, this might work fine.

Dan


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Lei Gao  
View profile  
 More options Nov 5 2012, 2:43 pm
From: Lei Gao <gao...@gmail.com>
Date: Mon, 5 Nov 2012 11:43:55 -0800 (PST)
Local: Mon, Nov 5 2012 2:43 pm
Subject: Re: Applying eventually consistent on Voldemort

Hi Anderson,

It seems that there are two issues you are facing - one is the centralized
inventory and one is the shopping cart items.  I think the solution for
each problem can be different.

The system is design of provide high write availability so you never reject
a customer request that adds items into the shopping cart. For this
purpose, you can configure you store as 2-1-1 and write a customer conflict
resolution to always merge the items in a shopping cart when concurrent
'adds' occurs to a shopping cart.

For the global inventory management, you have a couple options.

   - Use 2-1-1 configuration and prepare to back-order for the customer
   when you sell more than what you have.
   - Use 3-2-2 configuration and prepare to update the inventory in the
   database when inventory decreases more than what you've actually sold.
   - Partition your inventory instead of replicating it for high
   availability. But you will have to do some additional logic to re-adjust
   the inventory among partitions over time.

Thanks,

Lei


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »