a bit of debugging
This commit is contained in:
parent
dfb77d3547
commit
ad1eea1e8e
1 changed files with 3 additions and 0 deletions
3
db/db.go
3
db/db.go
|
@ -3,6 +3,7 @@ package db
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"database/sql"
|
"database/sql"
|
||||||
|
"time"
|
||||||
|
|
||||||
"github.com/lbryio/lbry.go/dht/bits"
|
"github.com/lbryio/lbry.go/dht/bits"
|
||||||
"github.com/lbryio/lbry.go/extras/errors"
|
"github.com/lbryio/lbry.go/extras/errors"
|
||||||
|
@ -121,7 +122,9 @@ func (s *SQL) HasBlobs(hashes []string) (map[string]bool, error) {
|
||||||
logQuery(query, args...)
|
logQuery(query, args...)
|
||||||
|
|
||||||
err := func() error {
|
err := func() error {
|
||||||
|
startTime := time.Now()
|
||||||
rows, err := s.conn.Query(query, args...)
|
rows, err := s.conn.Query(query, args...)
|
||||||
|
log.Debugf("hashes query took %s", time.Since(startTime))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return errors.Err(err)
|
return errors.Err(err)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue