Flush on the GUI works but not from spy.memcached


#1

Hello,
Is is possible for you to move your application to the latest Couchbase SDK?
http://www.couchbase.com/develop/java/current
With the latest Couchbase client you will be able to do:

List uris = new ArrayList();
uris.add(URI.create(“http://your-host:8091/pools”));
CouchbaseClient client = new CouchbaseClient(uris, “default”, “”);
Boolean response = client.flush().get();

Will also check why you have an issue with Spy2.8.2
Regards
Tug


#2

Please assist or we will not be able to upgrade to 2.0
And yes i know it is against recommended practice to do a flush.
Java code that invokes flush from spymemcached (worked with 1.8.x and spy.memcached 2.7.3)
MemcachedClientIF cacheClient = getClient(cache.getBucketName());
cacheClient.flush().get();
We moved to spy.memcached 2.8.2 with no luck.
Thank you


#3

In Couchbase Server, flush() needs to be handled a bit differently and spymemcached does only a flush that Couchbase Server cannot handle.
As Tug says, you can use the CouchbaseClient, but there is unfortunately one other minor bug in Couchbase Server 2.0 relating to flush. Currently, you have to use the Administrator username/password.
Your best way to use flush with Couchbase Server 2.0 is to first enable flush on the cluster, then use the ClusterManager class with the Administrator credentials from Couchbase Client 1.1 to perform your flush().


#4

Note the bug tracking this on Couchbase Server is MB-7381.