feat(backend/db): removed unnecessary logs
This commit is contained in:
parent
3300822bc8
commit
7e53bcf17c
2 changed files with 1 additions and 8 deletions
6
backend/pkg/db/cache/pg-cache.go
vendored
6
backend/pkg/db/cache/pg-cache.go
vendored
|
|
@ -13,11 +13,6 @@ type ProjectMeta struct {
|
||||||
expirationTime time.Time
|
expirationTime time.Time
|
||||||
}
|
}
|
||||||
|
|
||||||
// !TODO: remove old sessions by timeout to avoid memleaks
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Cache layer around the stateless PG adapter
|
|
||||||
**/
|
|
||||||
type PGCache struct {
|
type PGCache struct {
|
||||||
*postgres.Conn
|
*postgres.Conn
|
||||||
sessions map[uint64]*Session
|
sessions map[uint64]*Session
|
||||||
|
|
@ -26,7 +21,6 @@ type PGCache struct {
|
||||||
projectExpirationTimeout time.Duration
|
projectExpirationTimeout time.Duration
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: create conn automatically
|
|
||||||
func NewPGCache(pgConn *postgres.Conn, projectExpirationTimeoutMs int64) *PGCache {
|
func NewPGCache(pgConn *postgres.Conn, projectExpirationTimeoutMs int64) *PGCache {
|
||||||
return &PGCache{
|
return &PGCache{
|
||||||
Conn: pgConn,
|
Conn: pgConn,
|
||||||
|
|
|
||||||
|
|
@ -55,8 +55,7 @@ func NewConn(url string, queueLimit, sizeLimit int, metrics *monitoring.Metrics)
|
||||||
}
|
}
|
||||||
c, err := pgxpool.Connect(context.Background(), url)
|
c, err := pgxpool.Connect(context.Background(), url)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Println(err)
|
log.Fatalf("pgxpool.Connect err: %s", err)
|
||||||
log.Fatalln("pgxpool.Connect Error")
|
|
||||||
}
|
}
|
||||||
conn := &Conn{
|
conn := &Conn{
|
||||||
batches: make(map[uint64]*pgx.Batch),
|
batches: make(map[uint64]*pgx.Batch),
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue