4 ms·
This way, the connection runs the request instead of the other way round. I don't know if I'd call it an issue with the API -- there is a pretty active debate
by coffeemug 14y ago
This way, the connection runs the request instead of the other way round.
I don't know if I'd call it an issue with the API -- there is a pretty active debate going on about it: https://github.com/rethinkdb/rethinkdb/issues/256 https://github.com/rethinkdb/rethinkdb/issues/256 Please chime in there with your POV, it would really help!
how expensive is the creation of a new connection?
Connections aren't thread safe on the clients. It's very efficient to open a connection to the server, but it still requires a TCP handshake. This is a good low-level API -- we'll build a connection pool on top of that soon (I just opened an issue for it here -- https://github.com/rethinkdb/rethinkdb/issues/281 https://github.com/rethinkdb/rethinkdb/issues/281). People seem to want one because they're used to one, but it hasn't really been necessary in our testing.