Lifecycle of connections between client and FDB Processes


I am new to Foundationdb, and I had a query where I’m interested to know the lifecycle of connections between the client and FDB processes (Couldn’t find an answer in the documentation). Specifically, my query can be broken down into three questions as below:

  1. How many connections does a client open while making a connection? And connections to what? (If any of them are different from the ones mentioned here)

  2. How long are these connections open for (per transaction or per client)?

  3. Does the client have to close the above connections or does it happen automatically?

I would love to understand this better and any help will be appreciated. Thanks!

That actually is the thread that I was going to suggest you look at. I believe we ended with a reasonably accurate diagram, and if you have further questions, you’re welcome to ask.

One connection is opened from the client, and once the connection is opened, it’s maintained as open essentially indefinitely. At some point, FDB will likely do a better job of closing connections that aren’t being used, bit it will still be done transparently.

To be clear, this isn’t like MySQL/Postgres where you need to explicitly open, maintain, and reuse a connection. All of that is handled for you, and multiple requests will be multiplexed over the same connection if destined for the same server.