Documentation ¶
Index ¶
- Constants
- func DisableSignalHandling(config *server.Config)
- func NewServerService(serv *server.Server, servicesToWaitFor func() []services.Service) services.Service
- func ThanosTracerStreamInterceptor(srv interface{}, ss grpc.ServerStream, _ *grpc.StreamServerInfo, ...) error
- func ThanosTracerUnaryInterceptor(ctx context.Context, req interface{}, _ *grpc.UnaryServerInfo, ...) (interface{}, error)
- type Config
- type Cortex
- type RuntimeConfigValues
Constants ¶
const ( API string = "api" Ring string = "ring" RuntimeConfig string = "runtime-config" Overrides string = "overrides" OverridesExporter string = "overrides-exporter" Server string = "server" Distributor string = "distributor" DistributorService string = "distributor-service" Ingester string = "ingester" IngesterService string = "ingester-service" Flusher string = "flusher" Querier string = "querier" Queryable string = "queryable" StoreQueryable string = "store-queryable" QueryFrontend string = "query-frontend" QueryFrontendTripperware string = "query-frontend-tripperware" DeleteRequestsStore string = "delete-requests-store" RulerStorage string = "ruler-storage" Ruler string = "ruler" Configs string = "configs" AlertManager string = "alertmanager" Compactor string = "compactor" StoreGateway string = "store-gateway" MemberlistKV string = "memberlist-kv" TenantDeletion string = "tenant-deletion" Purger string = "purger" QueryScheduler string = "query-scheduler" TenantFederation string = "tenant-federation" All string = "all" )
The various modules that make up Cortex.
Variables ¶
This section is empty.
Functions ¶
func DisableSignalHandling ¶ added in v1.2.0
DisableSignalHandling puts a dummy signal handler
func NewServerService ¶ added in v0.7.0
func NewServerService(serv *server.Server, servicesToWaitFor func() []services.Service) services.Service
NewServerService constructs service from Server component. servicesToWaitFor is called when server is stopping, and should return all services that need to terminate before server actually stops. N.B.: this function is NOT Cortex specific, please let's keep it that way. Passed server should not react on signals. Early return from Run function is considered to be an error.
func ThanosTracerStreamInterceptor ¶ added in v1.4.0
func ThanosTracerStreamInterceptor(srv interface{}, ss grpc.ServerStream, _ *grpc.StreamServerInfo, handler grpc.StreamHandler) error
ThanosTracerStreamInterceptor injects the opentracing global tracer into the context in order to get it picked up by Thanos components.
func ThanosTracerUnaryInterceptor ¶ added in v1.4.0
func ThanosTracerUnaryInterceptor(ctx context.Context, req interface{}, _ *grpc.UnaryServerInfo, handler grpc.UnaryHandler) (interface{}, error)
ThanosTracerUnaryInterceptor injects the opentracing global tracer into the context in order to get it picked up by Thanos components.
Types ¶
type Config ¶
type Config struct { Target flagext.StringSliceCSV `yaml:"target"` AuthEnabled bool `yaml:"auth_enabled"` PrintConfig bool `yaml:"-"` HTTPPrefix string `yaml:"http_prefix"` ExternalQueryable prom_storage.Queryable `yaml:"-"` ExternalPusher ruler.Pusher `yaml:"-"` API api.Config `yaml:"api"` Server server.Config `yaml:"server"` Distributor distributor.Config `yaml:"distributor"` Querier querier.Config `yaml:"querier"` IngesterClient client.Config `yaml:"ingester_client"` Ingester ingester.Config `yaml:"ingester"` Flusher flusher.Config `yaml:"flusher"` Storage storage.Config `yaml:"storage"` LimitsConfig validation.Limits `yaml:"limits"` Prealloc cortexpb.PreallocConfig `yaml:"prealloc" doc:"hidden"` Worker querier_worker.Config `yaml:"frontend_worker"` Frontend frontend.CombinedFrontendConfig `yaml:"frontend"` QueryRange queryrange.Config `yaml:"query_range"` BlocksStorage tsdb.BlocksStorageConfig `yaml:"blocks_storage"` Compactor compactor.Config `yaml:"compactor"` StoreGateway storegateway.Config `yaml:"store_gateway"` TenantFederation tenantfederation.Config `yaml:"tenant_federation"` Ruler ruler.Config `yaml:"ruler"` RulerStorage rulestore.Config `yaml:"ruler_storage"` Configs configs.Config `yaml:"configs"` Alertmanager alertmanager.MultitenantAlertmanagerConfig `yaml:"alertmanager"` AlertmanagerStorage alertstore.Config `yaml:"alertmanager_storage"` RuntimeConfig runtimeconfig.Config `yaml:"runtime_config"` MemberlistKV memberlist.KVConfig `yaml:"memberlist"` QueryScheduler scheduler.Config `yaml:"query_scheduler"` Tracing tracing.Config `yaml:"tracing"` }
Config is the root config for Cortex.
func (*Config) RegisterFlags ¶
RegisterFlags registers flag.
type Cortex ¶
type Cortex struct { Cfg Config // set during initialization ServiceMap map[string]services.Service ModuleManager *modules.Manager API *api.API Server *server.Server Ring *ring.Ring TenantLimits validation.TenantLimits Overrides *validation.Overrides Distributor *distributor.Distributor Ingester *ingester.Ingester Flusher *flusher.Flusher Frontend *frontendv1.Frontend RuntimeConfig *runtimeconfig.Manager TombstonesLoader purger.TombstonesLoader QuerierQueryable prom_storage.SampleAndChunkQueryable ExemplarQueryable prom_storage.ExemplarQueryable QuerierEngine v1.QueryEngine QueryFrontendTripperware tripperware.Tripperware Ruler *ruler.Ruler RulerStorage rulestore.RuleStore ConfigAPI *configAPI.API ConfigDB db.DB Alertmanager *alertmanager.MultitenantAlertmanager Compactor *compactor.Compactor StoreGateway *storegateway.StoreGateway MemberlistKV *memberlist.KVInitService // Queryables that the querier should use to query the long // term storage. It depends on the storage engine used. StoreQueryables []querier.QueryableWithFilter }
Cortex is the root datastructure for Cortex.
type RuntimeConfigValues ¶ added in v1.16.0
type RuntimeConfigValues struct { TenantLimits map[string]*validation.Limits `yaml:"overrides"` Multi kv.MultiRuntimeConfig `yaml:"multi_kv_config"` IngesterChunkStreaming *bool `yaml:"ingester_stream_chunks_when_using_blocks"` IngesterLimits *ingester.InstanceLimits `yaml:"ingester_limits"` }
RuntimeConfigValues are values that can be reloaded from configuration file while Cortex is running. Reloading is done by runtime_config.Manager, which also keeps the currently loaded config. These values are then pushed to the components that are interested in them.