Description
Scope, Collection and Bucket classes holds a reference to Connection. When all the connections are closed on the cluster, these classes mantains the reference to a destroyed connection, causing a SEGFAULT.
```javascript
const cluster = new cb.Cluster('...');
const bucket = cluster.bucket('default');
const collection = bucket.defaultCollection()
const r1 = await collection.get('...')
console.log('response 1', r1)
await cluster.close(); // close all connections
//await cluster._connect() // <--- SEGFAULT here
const r2 = await collection.get('...') // <--- SEGFAULT here
console.log('response 2', r2)
```
Attachments
For Gerrit Dashboard: JSCBC-673 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
121518,4 | Fix JSCBC-669 | master | couchnode | Status: ABANDONED | 0 | 0 |
123226,5 | JSCBC-673: Correctly error operations performed after close. | master | couchnode | Status: MERGED | -1 | +1 |