Documentation
¶
Index ¶
- type Config
- type Ingester
- func (i *Ingester) CheckReady(ctx context.Context) error
- func (i *Ingester) Flush()
- func (i *Ingester) GetOrCreateInstance(instanceID string) (*instance, error)
- func (i *Ingester) Push(ctx context.Context, req *logproto.PushRequest) (*logproto.PushResponse, error)
- func (i *Ingester) Query(req *logproto.QueryPatternsRequest, stream logproto.Pattern_QueryServer) error
- func (i *Ingester) ServeHTTP(w http.ResponseWriter, r *http.Request)
- func (i *Ingester) TransferOut(_ context.Context) error
- func (*Ingester) Watch(*grpc_health_v1.HealthCheckRequest, grpc_health_v1.Health_WatchServer) error
- type IngesterQuerier
- type Limits
- type ResponseFromIngesters
- type RingClient
- type TeeConfig
- type TeeService
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Enabled bool `yaml:"enabled,omitempty" doc:"description=Whether the pattern ingester is enabled."`
LifecyclerConfig ring.LifecyclerConfig `` /* 153-byte string literal not displayed */
ClientConfig clientpool.Config `yaml:"client_config,omitempty" doc:"description=Configures how the pattern ingester will connect to the ingesters."`
ConcurrentFlushes int `yaml:"concurrent_flushes"`
FlushCheckPeriod time.Duration `yaml:"flush_check_period"`
MaxClusters int `` /* 127-byte string literal not displayed */
MaxEvictionRatio float64 `` /* 177-byte string literal not displayed */
MetricAggregation aggregation.Config `` /* 133-byte string literal not displayed */
TeeConfig TeeConfig `yaml:"tee_config,omitempty" doc:"description=Configures the pattern tee which forwards requests to the pattern ingester."`
ConnectionTimeout time.Duration `yaml:"connection_timeout"`
MaxAllowedLineLength int `` /* 130-byte string literal not displayed */
// contains filtered or unexported fields
}
func (*Config) RegisterFlags ¶
func (cfg *Config) RegisterFlags(fs *flag.FlagSet)
RegisterFlags registers pattern ingester related flags.
type Ingester ¶
type Ingester struct {
services.Service
// contains filtered or unexported fields
}
func New ¶
func New(
cfg Config,
limits Limits,
ringClient RingClient,
metricsNamespace string,
registerer prometheus.Registerer,
logger log.Logger,
) (*Ingester, error)
func (*Ingester) CheckReady ¶
func (i *Ingester) CheckReady(ctx context.Context) error
ReadinessHandler is used to indicate to k8s when the ingesters are ready for the addition removal of another ingester. Returns 204 when the ingester is ready, 500 otherwise.
func (*Ingester) GetOrCreateInstance ¶
func (i *Ingester) GetOrCreateInstance(instanceID string) (*instance, error)
func (*Ingester) Push ¶
func (i *Ingester) Push(ctx context.Context, req *logproto.PushRequest) (*logproto.PushResponse, error)
func (*Ingester) Query ¶
func (i *Ingester) Query(req *logproto.QueryPatternsRequest, stream logproto.Pattern_QueryServer) error
func (*Ingester) ServeHTTP ¶
func (i *Ingester) ServeHTTP(w http.ResponseWriter, r *http.Request)
ServeHTTP implements the pattern ring status page.
func (*Ingester) TransferOut ¶
func (i *Ingester) TransferOut(_ context.Context) error
type IngesterQuerier ¶
type IngesterQuerier struct {
// contains filtered or unexported fields
}
func NewIngesterQuerier ¶
func NewIngesterQuerier(
cfg Config,
ringClient RingClient,
metricsNamespace string,
registerer prometheus.Registerer,
logger log.Logger,
) (*IngesterQuerier, error)
type ResponseFromIngesters ¶
type ResponseFromIngesters struct {
// contains filtered or unexported fields
}
type RingClient ¶
type RingClient interface {
services.Service
Ring() ring.ReadRing
GetClientFor(addr string) (ring_client.PoolClient, error)
}
func NewRingClient ¶
func NewRingClient(
cfg Config,
metricsNamespace string,
registerer prometheus.Registerer,
logger log.Logger,
) (RingClient, error)
type TeeConfig ¶ added in v3.2.0
type TeeConfig struct {
BatchSize int `yaml:"batch_size"`
BatchFlushInterval time.Duration `yaml:"batch_flush_interval"`
FlushQueueSize int `yaml:"flush_queue_size"`
FlushWorkerCount int `yaml:"flush_worker_count"`
StopFlushTimeout time.Duration `yaml:"stop_flush_timeout"`
}
func (*TeeConfig) RegisterFlags ¶ added in v3.2.0
func (cfg *TeeConfig) RegisterFlags(f *flag.FlagSet, prefix string)
type TeeService ¶ added in v3.2.0
type TeeService struct {
// contains filtered or unexported fields
}
func NewTeeService ¶ added in v3.2.0
func NewTeeService(
cfg Config,
limits Limits,
ringClient RingClient,
tenantCfgs *runtime.TenantConfigs,
metricsNamespace string,
registerer prometheus.Registerer,
logger log.Logger,
) (*TeeService, error)
func (*TeeService) Duplicate ¶ added in v3.2.0
func (ts *TeeService) Duplicate(tenant string, streams []distributor.KeyedStream)
Duplicate Implements distributor.Tee which is used to tee distributor requests to pattern ingesters.
func (*TeeService) Start ¶ added in v3.2.0
func (ts *TeeService) Start(runCtx context.Context) error
func (*TeeService) WaitUntilDone ¶ added in v3.2.0
func (ts *TeeService) WaitUntilDone()
Source Files
¶
Click to show internal directories.
Click to hide internal directories.