couchbase-shell icon indicating copy to clipboard operation
couchbase-shell copied to clipboard

Only connect to nodes as needed

Open chvck opened this issue 3 years ago • 1 comments

Currently as soon as a kv command is run we fetch a config and connect to all nodes. If a user has a large cluster and is doing a simple get then they're going to pay quite a large penalty here (I'm pretty sure we even connect synchronously). We should connect to nodes according to the keys that we see. This is certainly going to cause complications to do it in a performant way - we'll probably need per node queues or something for whilst a connection is happening. Although we can make that a later optimisation.

chvck avatar Dec 15 '21 08:12 chvck

This also needs thought about UX when only one node can't be contacted but we only try the connection toward the end of a long import. The user could always issue a ping command to check that first?

chvck avatar Oct 10 '22 16:10 chvck