Documentation ¶
Index ¶
- Constants
- func ConfigUsage(w io.Writer) error
- type CLI
- func (cli *CLI) CGErrorsCheck(consumer *input.KafkaConsumer)
- func (cli *CLI) CacheEvict(cache enricher.Enricher)
- func (cli *CLI) CacheRefresh(cache enricher.Enricher, negativeCache enricher.Enricher, ...)
- func (cli *CLI) EnricherChain(stats *debug.Stats) (*enricher.CFClient, enricher.Enricher, enricher.Enricher, error)
- func (cli *CLI) InputChain() (*input.KafkaConsumer, error)
- func (_ *CLI) Name() string
- func (cli *CLI) NegativeCacheEvict(negativeCache enricher.Enricher)
- func (cli *CLI) OutputChain(consumer *input.KafkaConsumer, stats *debug.Stats) (output.AsyncWriter, error)
- func (cli *CLI) Process(consumer input.Reader, cache enricher.Enricher, batcher output.AsyncWriter, ...) error
- func (cli *CLI) Run(logger *log.Logger) int
- func (cli *CLI) StatsEmit(stats *debug.Stats)
- func (cli *CLI) TrapSignals(consumer *input.KafkaConsumer)
- func (_ *CLI) Version() string
- type Config
Constants ¶
View Source
const ( ExitCodeOK int = 0 ExitCodeError int = 1 + iota )
Exit codes are int values that represent an exit code for a particular error.
Variables ¶
This section is empty.
Functions ¶
func ConfigUsage ¶
ConfigUsage lists the environment variables to be used for configuration
Types ¶
type CLI ¶
type CLI struct { // OutStream and ErrStream are the stdout and stderr to write message from the CLI. OutStream, ErrStream io.Writer Conf *Config //LogLevel string Logger *log.Logger }
CLI is the command line object
func (*CLI) CGErrorsCheck ¶
func (cli *CLI) CGErrorsCheck(consumer *input.KafkaConsumer)
func (*CLI) CacheEvict ¶
func (*CLI) CacheRefresh ¶
func (*CLI) EnricherChain ¶
func (*CLI) InputChain ¶
func (cli *CLI) InputChain() (*input.KafkaConsumer, error)
func (*CLI) NegativeCacheEvict ¶
func (*CLI) OutputChain ¶
func (cli *CLI) OutputChain(consumer *input.KafkaConsumer, stats *debug.Stats) (output.AsyncWriter, error)
func (*CLI) TrapSignals ¶
func (cli *CLI) TrapSignals(consumer *input.KafkaConsumer)
type Config ¶
type Config struct { CF enricher.ConfigCF InfluxDB output.ConfigInfluxDB Batcher output.ConfigBatcher Kafka input.ConfigKafka Server debug.ConfigServer MetadataRefresh time.Duration `default:"10m" desc:"How often to fetch a fresh copy of all metadata"` MetadataExpire time.Duration `default:"3m" desc:"How long before metadata is considered expired"` MetadataExpireCheck time.Duration `default:"1m" desc:"How often to check for expired metadata"` NegativeCacheExpire time.Duration `default:"20m" desc:"How long before negative cache is considered expired"` NegativeCacheExpireCheck time.Duration `default:"3m" desc:"How often to check for expired negative cache"` }
Config is the root configuration structure
func ConfigParse ¶
ConfigParse parses the CFMR_* environment vars to extract the configuration
Click to show internal directories.
Click to hide internal directories.