link with out changing data

Bryan Fink bryan at
Tue Jun 26 09:24:28 EDT 2012

On Tue, Jun 26, 2012 at 2:43 AM, Venki Yedidha
<venkatesh.yedidha at> wrote:
>                     I want to insert Country data first, whenever a city
> enters we should link this country to city with out changing the country
> data.

Hi, Venkatesh. As you have noticed, Riak does not support
partial-update operations. You must write the entire value of the
object every time. Most client libraries should make this easy for
you, by automatically remembering the value you read, and re-writing
it without change if you only modify some metadata (like links).

But, if keeping the country data off the wire during a link-changing
operation is your goal, my advice would be to use two objects: one for
your country data, and one for its links. This way you can change the
links object without touching the data object.


More information about the riak-users mailing list