initialise

package
v1.20.0 Latest Latest
Warning

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

Go to latest
Published: May 7, 2020 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Audit = iota
	GenerateDownloads
)

Possible names of Kafa Producers

Variables

This section is empty.

Functions

This section is empty.

Types

type ExternalServiceList

type ExternalServiceList struct {
	AuditProducer             bool
	GenerateDownloadsProducer bool
	Graph                     bool
	HealthCheck               bool
	MongoDB                   bool
}

ExternalServiceList represents a list of services

func (*ExternalServiceList) GetGraphDB

func (e *ExternalServiceList) GetGraphDB(ctx context.Context, cfg *config.Configuration) (*graph.DB, error)

GetGraphDB returns a graphDB

func (*ExternalServiceList) GetHealthCheck

func (e *ExternalServiceList) GetHealthCheck(cfg *config.Configuration, buildTime, gitCommit, version string) (healthcheck.HealthCheck, error)

GetHealthCheck creates a healthcheck with versionInfo

func (*ExternalServiceList) GetMongoDB

GetMongoDB returns a mongodb client and dataset mongo object

func (*ExternalServiceList) GetProducer

func (e *ExternalServiceList) GetProducer(ctx context.Context, kafkaBrokers []string, topic string, name KafkaProducerName, envMax int) (kafkaProducer *kafka.Producer, err error)

GetProducer returns a kafka producer, which might not be initialised yet.

type KafkaProducerName

type KafkaProducerName int

KafkaProducerName : Type for kafka producer name used by iota constants

func (KafkaProducerName) String

func (k KafkaProducerName) String() string

Values of the kafka producers names

Jump to

Keyboard shortcuts

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