Documentation
¶
Index ¶
Constants ¶
View Source
const ( ScanTableInterval = 24 * 3600 // scan all tables once everyday BestScanStartHour = 6 // start scan at 6am every day, I guess that is low peak time of most business DaysToDeleteOldTable = 10 // delete tables that are not updated for these days ShowStablesSql = "SHOW stables;" OldTableSqlFormat = "select * from (select last_row(_ts) as last_ts,tbname from `%s` group by tbname) where last_ts < now - %dd;" DropTableSqlFormat = "DROP TABLE IF EXISTS %s;" )
Variables ¶
This section is empty.
Functions ¶
func StartScanTables ¶
func StartScanTables(pool *ConnPool)
StartScanTables used to scan all tables and delete too old tables that not updated for days
Types ¶
type ConnPool ¶
type ConnPool struct { TaosServer config.TaosConfig PrepareSQL string ConnCount int32 // contains filtered or unexported fields }
func CreateConnPool ¶
func CreateConnPool(taosServer config.TaosConfig) *ConnPool
func (*ConnPool) SchemalessWrite ¶
Click to show internal directories.
Click to hide internal directories.