Details
-
Bug
-
Resolution: Fixed
-
Test Blocker
-
None
-
None
Description
Something along the lines of this, with best practices, if possible (I'm not a Node expert, can't offer that):
======
'use strict';
var couchbase = require('couchbase');
// Create a Couchbase Cluster connection
var cluster = new couchbase.Cluster('couchbase://localhost',
);
// Open a specific Couchbase bucket, `travel-sample` in this case.
var bucket = cluster.bucket('travel-sample');
// And select the default collection
var collection = bucket.defaultCollection();
// upsert document
async function upsertDocument(key, value)
upsertDocument("my-document",
{name: 'mike'});
// get document
async function getDocument()
{
await collection.get('airline_10123', function(err, result)
);
}
getDocument();
=======
If someone tries to use our current example, they won't get far. It's pretty frustrating.
Reporter: Oleg Kuzmin
E-mail: oleg.kuzmin@couchbase.com