postgrest-rs icon indicating copy to clipboard operation
postgrest-rs copied to clipboard

Save and re-use reqwest instance

Open option-greek opened this issue 3 years ago • 2 comments
trafficstars

Currently the reqwest client seem to be created always for executing a query:

let mut req = Client::new().request(self.method.clone(), &self.url);

This will end up doing a SSL handshake every time. It's better to create it once and reuse it to improve performance.

option-greek avatar Jan 10 '22 09:01 option-greek

Has this been resolved?

spencerbart avatar Sep 29 '22 22:09 spencerbart

Nope - PRs welcome though!

soedirgo avatar Sep 30 '22 04:09 soedirgo