config

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 24, 2025 License: Apache-2.0 Imports: 5 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Commons *shared.Commons `yaml:"-"` // don't use this directly as configuration for a service

	Service Service `yaml:"-"`

	Tracing *Tracing `yaml:"tracing"`
	Log     *Log     `yaml:"log"`
	Debug   Debug    `yaml:"debug"`

	GRPC          GRPCConfig            `yaml:"grpc"`
	GRPCClientTLS *shared.GRPCClientTLS `yaml:"grpc_client_tls"`
	GrpcClient    client.Client         `yaml:"-"`

	Events Events `yaml:"events"`
	Store  Store  `yaml:"store"`

	Context context.Context `yaml:"-"`
}

Config combines all available configuration parts.

type Debug

type Debug struct {
	Addr   string `` /* 177-byte string literal not displayed */
	Token  string `yaml:"token" env:"EVENTHISTORY_DEBUG_TOKEN" desc:"Token to secure the metrics endpoint." introductionVersion:"1.0.0"`
	Pprof  bool   `` /* 126-byte string literal not displayed */
	Zpages bool   `` /* 159-byte string literal not displayed */
}

Debug defines the available debug configuration.

type Events

type Events struct {
	Endpoint             string `` /* 250-byte string literal not displayed */
	Cluster              string `` /* 292-byte string literal not displayed */
	TLSInsecure          bool   `` /* 152-byte string literal not displayed */
	TLSRootCACertificate string `` /* 292-byte string literal not displayed */
	EnableTLS            bool   `` /* 262-byte string literal not displayed */
	AuthUsername         string `` /* 267-byte string literal not displayed */
	AuthPassword         string `` /* 267-byte string literal not displayed */
}

Events combines the configuration options for the event bus.

type GRPCConfig

type GRPCConfig struct {
	Addr      string                 `yaml:"addr" env:"EVENTHISTORY_GRPC_ADDR" desc:"The bind address of the GRPC service." introductionVersion:"1.0.0"`
	Namespace string                 `yaml:"-"`
	TLS       *shared.GRPCServiceTLS `yaml:"tls"`
}

GRPCConfig defines the available grpc configuration.

type Log

type Log struct {
	Level  string `` /* 191-byte string literal not displayed */
	Pretty bool   `` /* 129-byte string literal not displayed */
	Color  bool   `` /* 129-byte string literal not displayed */
	File   string `` /* 159-byte string literal not displayed */
}

Log defines the available log configuration.

type Service

type Service struct {
	Name string `yaml:"-"`
}

Service defines the available service configuration.

type Store

type Store struct {
	Store        string        `` /* 225-byte string literal not displayed */
	Nodes        []string      `` /* 367-byte string literal not displayed */
	Database     string        `` /* 135-byte string literal not displayed */
	Table        string        `yaml:"table" env:"EVENTHISTORY_STORE_TABLE" desc:"The database table the store should use." introductionVersion:"1.0.0"`
	TTL          time.Duration `` /* 231-byte string literal not displayed */
	AuthUsername string        `` /* 225-byte string literal not displayed */
	AuthPassword string        `` /* 225-byte string literal not displayed */
}

Store configures the store to use

type Tracing

type Tracing struct {
	Enabled   bool   `yaml:"enabled" env:"OC_TRACING_ENABLED;EVENTHISTORY_TRACING_ENABLED" desc:"Activates tracing." introductionVersion:"1.0.0"`
	Type      string `` /* 215-byte string literal not displayed */
	Endpoint  string `` /* 141-byte string literal not displayed */
	Collector string `` /* 261-byte string literal not displayed */
}

Tracing defines the available tracing configuration.

func (Tracing) Convert

func (t Tracing) Convert() tracing.Config

Convert Tracing to the tracing package's Config struct.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL