Couchbase
  • Why NoSQL?
  • Couchbase Server
  • Download
  • Resources
  • Careers
Home | Forums | SDKs | SDKs

Sync in spymemcached

3 replies [Last post]
  • Login or register to post comments
Mon, 10/31/2011 - 09:25
olicooper
Offline
Joined: 09/06/2011
Groups: None

Hi Guys,

Due to the fact that views won't update until an item has persisted to disk it is essential that we have some way of blocking until the item in a set/add has persisted to disk.

I've seen mention in various places that this sort of sync support is supposed to be coming in spymemcached. Any idea of when?

Given that the CouchDB style view stuff is currently so separate from the Membase-style cache stuff (i.e. views aren't cached and can't update from cache) it really is essential to have some way of knowing when the data you have written will be available in a view query.

To put it another way, what's the point in having a query block until a view has updated if the underlying data the view is updating from can be stale itself because there are still items waiting to be written from the cache to disk?

Thanks,

Oli.

Top
  • Login or register to post comments
Mon, 10/31/2011 - 10:33
mikew
Offline
Joined: 03/14/2011
Groups:

We have implemented an "observe" command that will allow you to do exactly everything mentioned in you post. We just finished the server side implementation and the command is undergoing QA testing. We haven't publicly disclosed how this command will work yet since it's not quite finished though. The command is currently scheduled for completion for the release of Couchbase Server 2.0 and it is on track to be finished.

As a developer you will most likely never interact with this command. What you will likely see in Spymemcached is a new function called something like setAndPersist() which will return a Future. The call will be asynchronous by default, but calling get() on the future will cause your application thread to block until the item has been persisted to disk.

Top
  • Login or register to post comments
Mon, 10/31/2011 - 10:40
olicooper
Offline
Joined: 09/06/2011
Groups: None

Thanks Mike, that sounds like just the thing.

Any chance of getting hold of a preview version when the work is finished if that is before release? We are being badly affected by these view issues and currently are having to put threads to sleep for many seconds to be sure items are persisting to disk.

Top
  • Login or register to post comments
Mon, 10/31/2011 - 10:49
mikew
Offline
Joined: 03/14/2011
Groups:

Your best bet is to just wait for the next developer preview of Couchbase Server, otherwise you will have to build the server yourself and the code might still have some issues since you will be using a nightly build.

I also haven't done any work on Spymemcached yet to get the observe stuff added. I'll do my best to try to keep this post updated, but check back with us when we release the next Couchbase Server 2.0 build in case I forget.

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