Documentation
¶
Index ¶
- Variables
- func DumpGoRoutine()
- func GetNewSyslogSink(namespace string) *gosteno.Syslog
- func NewLogger(verbose bool, logFilePath, name string, config Config) *gosteno.Logger
- func ReadConfigInto(config interface{}, configPath string) error
- func RegisterGoRoutineDumpSignalChannel() chan os.Signal
- type Component
- type Config
- type HealthMonitor
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultYagnatsClientProvider = func(logger *gosteno.Logger, c *Config) (natsClient yagnats.NATSClient, err error) { members := []yagnats.ConnectionProvider{} for _, natsHost := range c.NatsHosts { members = append(members, &yagnats.ConnectionInfo{ Addr: fmt.Sprintf("%s:%d", natsHost, c.NatsPort), Username: c.NatsUser, Password: c.NatsPass, }) } connectionInfo := &yagnats.ConnectionCluster{ Members: members, } natsClient = yagnats.NewClient() err = natsClient.Connect(connectionInfo) if err != nil { return nil, errors.New(fmt.Sprintf("Could not connect to NATS: %v", err.Error())) } return natsClient, nil }
View Source
var Logger *gosteno.Logger
Functions ¶
func DumpGoRoutine ¶
func DumpGoRoutine()
func GetNewSyslogSink ¶
func ReadConfigInto ¶
Types ¶
type Component ¶
type Component struct {
*gosteno.Logger
IpAddress string
HealthMonitor HealthMonitor
Type string //Used by the collector to find data processing class
Index uint
UUID string
StatusPort uint32
StatusCredentials []string
Instrumentables []instrumentation.Instrumentable
}
func NewComponent ¶
func NewComponent(logger *gosteno.Logger, componentType string, index uint, heathMonitor HealthMonitor, statusPort uint32, statusCreds []string, instrumentables []instrumentation.Instrumentable) (Component, error)
func (Component) StartMonitoringEndpoints ¶
type Config ¶
type HealthMonitor ¶
type HealthMonitor interface {
Ok() bool
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.