Skip to content

Instantly share code, notes, and snippets.

@bhawna94
Last active April 16, 2019 07:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bhawna94/7e7d1cf2c1fef8793f71f4779dcc5d9b to your computer and use it in GitHub Desktop.
Save bhawna94/7e7d1cf2c1fef8793f71f4779dcc5d9b to your computer and use it in GitHub Desktop.
//Connecting Synchronously
Cluster cluster = CouchbaseCluster.create("node1");
cluster.authenticate("username","password");
Bucket bucket = cluster.openBucket("bucketname");
//Connecting Asynchronously
AsyncCluster cluster = CouchbaseAsyncCluster.create("node1")
Observable<AsyncBucket> bucket = cluster.openBucket("bucketname")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment