From cf678c9e4b2b975ce4db8a6a0400d842d8353be6 Mon Sep 17 00:00:00 2001 From: Serhat Karabulut Date: Sat, 14 Sep 2024 09:30:04 +0300 Subject: [PATCH] chore: decrease hypertable check ticker duration --- pq/timescaledb/hypertable.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pq/timescaledb/hypertable.go b/pq/timescaledb/hypertable.go index bd3734a..1676a53 100644 --- a/pq/timescaledb/hypertable.go +++ b/pq/timescaledb/hypertable.go @@ -29,7 +29,7 @@ func NewTimescaleDB(ctx context.Context, dsn string) (*TimescaleDB, error) { return nil, errors.Wrap(err, "new postgresql connection") } - return &TimescaleDB{conn: conn, ticker: time.NewTicker(time.Minute * 5)}, nil + return &TimescaleDB{conn: conn, ticker: time.NewTicker(time.Second)}, nil } func (tdb *TimescaleDB) SyncHyperTables(ctx context.Context) { @@ -55,6 +55,7 @@ func (tdb *TimescaleDB) FindHyperTables(ctx context.Context) (map[string]string, return nil, nil } } + return nil, errors.Wrap(err, "hyper tables result") }