@jrawsthorne
Hi, continuing on the previous topic my app crash on connection.
I found the issue, I was using the old deprecated connection method :
new couchbase.Cluster(config.connstr, { username: config.user, password: config.user_pwd });
This does produce a segmentation fault.
Using the new method does not crash.
I was using the old method because the new one have a different format for the connection string and I don’t know how to adapt to the new one( I think there was no example at the time), before I was just passing “host1:port,host2:port”, the new format start with “couchbase://”, it doesn’t parse correctly the old format with the new method.
Anyway, we fixed one problem and I just found another.
I have the following connection string connstr: “couchbase://192.168.1.4,192.168.1.2”.
The first host is not a valid host on purpose, to mimic a host down, so it should connect with the second host. With the old sdk I can connect just fine the new sdk produce “unhandledRejection UnambiguousTimeoutError: unambiguous timeout”
Hey @00christian00 , thanks so much for letting us know what you’re seeing.
One known cause of some crashes is that in some (believed to be rare) cases we see a segfault if you process.exit(). This leads to some threads not getting to complete background tasks. If you just instead let all of the events be handled before exit, you won’t see this. I found this bug myself, actually.
Interesting-- I thought we had this kind of negative case tested. Is it possible that it still connects, but also produces an error? I’ll have a look and file a bug if appropriate.
It looks like the first of those has already merged, so it will be picked up in the next maintenance release. Hopefully that works for you @00christian00 ; if you’re an Enterprise subscriber and need something earlier, you can certainly engage support.