Versions in this module Expand all Collapse all v3 v3.0.1 Mar 21, 2022 v3.0.0 Mar 21, 2022 Changes in this version + const AlertForStateMetricName + const MetricsPrefix + func ForStateMetric(base labels.Labels, alertName string) labels.Labels + func MultiTenantManagerAdapter(mgr ruler.MultiTenantManager) ruler.MultiTenantManager + func MultiTenantRuleManager(cfg Config, engine *logql.Engine, overrides RulesLimits, logger log.Logger, ...) ruler.ManagerFactory + func NewRuler(cfg Config, engine *logql.Engine, reg prometheus.Registerer, logger log.Logger, ...) (*ruler.Ruler, error) + func ValidateGroups(grps ...rulefmt.RuleGroup) (errs []error) + type Config struct + RemoteWrite RemoteWriteConfig + WAL instance.Config + WALCleaner cleaner.Config + func (c *Config) RegisterFlags(f *flag.FlagSet) + func (c *Config) Validate() error + type GroupLoader struct + func (GroupLoader) Parse(query string) (parser.Expr, error) + func (g GroupLoader) Load(identifier string) (*rulefmt.RuleGroups, []error) + type MemStore struct + func NewMemStore(userID string, queryFunc rules.QueryFunc, metrics *memstoreMetrics, ...) *MemStore + func (m *MemStore) Querier(ctx context.Context, mint, maxt int64) (storage.Querier, error) + func (m *MemStore) Start(iter RuleIter) + func (m *MemStore) Stop() + type MultiTenantManager struct + func (m *MultiTenantManager) GetRules(userID string) []*rules.Group + func (m *MultiTenantManager) Stop() + func (m *MultiTenantManager) SyncRuleGroups(ctx context.Context, ruleGroups map[string]rulespb.RuleGroupList) + func (m *MultiTenantManager) ValidateRuleGroup(grp rulefmt.RuleGroup) []error + type RemoteWriteConfig struct + Client config.RemoteWriteConfig + ConfigRefreshPeriod time.Duration + Enabled bool + func (c *RemoteWriteConfig) Clone() (*RemoteWriteConfig, error) + func (c *RemoteWriteConfig) RegisterFlags(f *flag.FlagSet) + func (c *RemoteWriteConfig) Validate() error + type RuleCache struct + func NewRuleCache(metrics *memstoreMetrics) *RuleCache + func (c *RuleCache) CleanupOldSamples(olderThan time.Time) (empty bool) + func (c *RuleCache) Get(ts time.Time, ls labels.Labels) (*promql.Sample, bool) + func (c *RuleCache) Set(ts time.Time, vec promql.Vector) + type RuleIter interface + AlertingRules func() []*rules.AlertingRule + type RulesLimits interface + RulerRemoteWriteDisabled func(userID string) bool + RulerRemoteWriteHeaders func(userID string) map[string]string + RulerRemoteWriteQueueBatchSendDeadline func(userID string) time.Duration + RulerRemoteWriteQueueCapacity func(userID string) int + RulerRemoteWriteQueueMaxBackoff func(userID string) time.Duration + RulerRemoteWriteQueueMaxSamplesPerSend func(userID string) int + RulerRemoteWriteQueueMaxShards func(userID string) int + RulerRemoteWriteQueueMinBackoff func(userID string) time.Duration + RulerRemoteWriteQueueMinShards func(userID string) int + RulerRemoteWriteQueueRetryOnRateLimit func(userID string) bool + RulerRemoteWriteRelabelConfigs func(userID string) []*util.RelabelConfig + RulerRemoteWriteTimeout func(userID string) time.Duration + RulerRemoteWriteURL func(userID string) string Other modules containing this package github.com/pao214/loki/v2