Documentation
¶
Overview ¶
Package housekeeper provides functionality for managing and maintaining database tables with specific conditions and retention policies.
The package defines a Table structure to represent a database table along with its associated metadata, such as timestamp and date columns, a condition for filtering rows, and a minimum retention period in days.
It also provides a thread-safe mechanism to register and manage tables using a global map protected by a mutex.
Index ¶
Constants ¶
View Source
const DefaultRetentionDays = 30
Variables ¶
Functions ¶
Types ¶
type Housekeeper ¶
type Housekeeper struct {
// contains filtered or unexported fields
}
func New ¶
func New(p Params) *Housekeeper
type Table ¶
type Table struct {
Table jet.Table
TimestampColumn jet.ColumnTimestamp
DateColumn jet.ColumnDate
Condition jet.BoolExpression
MinDays int
}
Click to show internal directories.
Click to hide internal directories.