reduced the places where we probe hourly tables
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -137,15 +137,9 @@ ORDER BY snapshot_time ASC
|
||||
if err := db.ValidateTableName(t.Table); err != nil {
|
||||
continue
|
||||
}
|
||||
if t.Count.Valid {
|
||||
if t.Count.Int64 <= 0 {
|
||||
continue
|
||||
}
|
||||
} else {
|
||||
hasRows, err := db.TableHasRows(ctx, dbConn, t.Table)
|
||||
if err != nil || !hasRows {
|
||||
continue
|
||||
}
|
||||
// Trust snapshot_count if present; otherwise optimistically include to avoid long probes.
|
||||
if t.Count.Valid && t.Count.Int64 <= 0 {
|
||||
continue
|
||||
}
|
||||
tables = append(tables, t)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user