Node.js SDK 3.2.0 connecting with Couchbase enterprise Edition 6.6.2 build 9588 ‧ IPv4 , code crashes with segmentation fault

Hello,

I have following code running on RHAT8 with node v14.16.0 . I am using latest Node SDK 3.2.0 which results in segmentation fault as shown below.

const couchbase = require(‘couchbase’);

//const DB_URL= ‘couchbase://localhost’;
const DB_URL = ‘http://127.0.0.1:8091’;
const DB_USER = ‘’;
const DB_PASSWORD = ‘’;
const DB_BUCKET = ‘folio-postings’ ;

const connOptions = {
username: DB_USER,
password: DB_PASSWORD
};
const cluster = new couchbase.Cluster(DB_URL, connOptions);
const bucket = cluster.bucket(DB_BUCKET);
cluster.diagnostics().then(res => {

        console.log("[Couchbase] - Connection successful");

}).catch(err => {

        console.log('[Couchbase] - Connection error => ', err);

});
const collection = bucket.defaultCollection();
collection.get(“folio_81231111”, (err, rows) => {
if (err) {
console.log(err);
} else {
console.log(rows.value);
}
})

When I run above code I get segmentation fault:

[Couchbase] - Connection successful
Segmentation fault (core dumped)

If I run the same exact code and setting with Node.js SDK 3.1.1, it works fine. I see that Couchbase 6.5 is compatible with SDK 3.2.0 . Please advise what might be the issue.

Thank you for your help.
Ben

Thank you @Ben_Kot for your question and welcome to the forums.

We are aware of this issue and are working to resolve this in our next release. Thank you again for your patience and support.

Hey @Ben_Kot ,

We managed to identify the cause of this segfault and have a fix in progress. It will ship in our upcoming release and you can watch for more details here: https://issues.couchbase.com/browse/JSCBC-916

Cheers, Brett