bb8::ConnectionManager has is_valid and has_broken methods. In make_pooled, there is no option to use has_broken.
Introducing a feature flag called use_has_broken_as_valid_check, with this feature flag, the is_valid method of bb8::ConnectionManager uses the has_broken method of r2d2's ManageConnection.
For Diesel, the has_broken method uses the is_broken method of Diesel Connection. 'Select 1' can be avoided for every get from the connection pool.
bb8::ConnectionManager has is_valid and has_broken methods. In make_pooled, there is no option to use has_broken.
Introducing a feature flag called
use_has_broken_as_valid_check
, with this feature flag, the is_valid method of bb8::ConnectionManager uses the has_broken method of r2d2's ManageConnection.For Diesel, the has_broken method uses the is_broken method of Diesel Connection. 'Select 1' can be avoided for every get from the connection pool.