Couchbase
  • Why NoSQL?
  • Couchbase Server
  • Download
  • Resources
  • Careers
Home | Forums | Membase | Membase Server 1.7.x

synchronized access to membase

1 reply [Last post]
  • Login or register to post comments
Mon, 01/16/2012 - 10:13
yamahabob
Offline
Joined: 01/09/2012
Groups: None

I'm changing some code from using a synchronized map in Java to a using Membase. Is there a way to have the functionality of synchronization across threads with Membase? As of now, I'm using two multiple threads to create tuples by generating random number keys, and if done right, two threads will try to add the same key. I'm not sure on the protocol, but I believe if the index already exists, the functionality of the add will be the same as a touch? If there were anyway to avoid this though, that would be preferable.

Thanks in advance

Top
  • Login or register to post comments
Fri, 02/03/2012 - 13:03
mikew
Offline
Joined: 03/14/2011
Groups:

Take a look at the memcached cas operation. It will allow you to update an operation only if no one else has changed it before you do.

Top
  • Login or register to post comments
  • Login or register to post comments
  • Login
  • Register

Company

  • About Us
  • Leadership
  • Customers
  • Partners
  • Contact Us

Product

  • Couchbase Server
  • Couchbase SDKs
  • Use Cases
  • Documentation
  • Forums

Open Source

  • Couchbase Project
  • Couchbase vs. CouchDB

Commercial

  • Subscriptions & Support
  • Training & Services

News

  • Blog
  • Newsletter
  • Press Releases
  • Buzz

Follow Us

    
  • Customer Login
  • Terms of Service
  • Privacy Policy
  • Trademark Policy
  • Site Map

© 2013 COUCHBASE All rights reserved.

Sign in to Couchbase Community

close
  • Create new account
  • Request new password
You are logging into the Forums, Wiki and Issue Tracker