config

package
v0.8.6-alpha Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Version     = "dev"
	BuildCommit = ""
	BuildDate   = ""
)

Functions

This section is empty.

Types

type Config

type Config struct {
	Port string `default:"8080"`
	// Timeout represents graceful shutdown period. Defaults to 60 seconds.
	Timeout       time.Duration `default:"60s"`
	CacheSizeInMB int64         `default:"100"`
	GRPC          GRPCConfig
	NewRelic      NewRelicConfig
	DB            DBConfig
	KafkaProducer KafkaProducerConfig
	StatsD        StatsDConfig
	SchemaChange  SchemaChangeConfig
}

Config Server config

func Load

func Load(configFile string) (Config, error)

type DBConfig

type DBConfig struct {
	ConnectionString string
}

DBConfig contains DB connection details

type GRPCConfig

type GRPCConfig struct {
	MaxRecvMsgSizeInMB int `default:"10"`
	MaxSendMsgSizeInMB int `default:"10"`
}

GRPCConfig grpc options

type KafkaProducerConfig added in v0.8.0

type KafkaProducerConfig struct {
	BootstrapServer string
	Retries         int `default:"5"`
	Timeout         int `default:"5000"`
}

Kafka Producer Config

type NewRelicConfig

type NewRelicConfig struct {
	Enabled bool   `default:"false"`
	AppName string `default:"stencil"`
	License string
}

NewRelicConfig contains the New Relic go-agent configuration

type SchemaChangeConfig added in v0.8.0

type SchemaChangeConfig struct {
	KafkaTopic string
	Depth      int32
	Enable     bool `default:"false"`
}

SchameChangeConfig

type StatsDConfig added in v0.8.0

type StatsDConfig struct {
	Address string
	Prefix  string
}

StatsDConfig

Jump to

Keyboard shortcuts

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