storj/private/dbutil/cockroachutil
Natalie Villasana 3cc1a0b393 dbutil/cockroachutil: make crdb retry when tcp error
Adds checks in the existing NeedsRetry cockroachutil method
to see if the error is from the net package and a tcp error,
in which case it should retry. Also adds checks for if the
error contains EOF-- we don't retry in this case because it's
unclear if the query succeeded or failed.
These checks are needed to prevent our app from crashing when
it gets "connection reset by peer" and other tcp errors that
we've seen frequently coming from the metainfo loop.

Change-Id: I194d4b120082393cb6dbda2dd86b44f4696a66a4
2021-02-08 08:49:22 +00:00
..
db.go all: minor cleanups 2020-12-16 10:47:46 +00:00
driver_test.go private/dbutil/pgtest: support multiple databases for testing 2020-04-28 21:55:49 +03:00
driver.go dbutil/cockroachutil: make crdb retry when tcp error 2021-02-08 08:49:22 +00:00
openunique_test.go private/{dbutil,tagsql}: pass ctx to database opening 2020-10-29 10:51:29 +00:00