Documentation ¶
Index ¶
Constants ¶
View Source
const ( NO_MESSAGE_PROVIDED = "no message" LOGTYPE_APPLICATIONLOG = "applog" LOGTYPE_ACCESSLOG = "accesslog" )
Variables ¶
This section is empty.
Functions ¶
func NewKafkaAdapter ¶
func NewKafkaAdapter(route *router.Route) (router.LogAdapter, error)
Types ¶
type DockerFields ¶
type KafkaAdapter ¶
type KafkaAdapter struct {
// contains filtered or unexported fields
}
func (*KafkaAdapter) Stream ¶
func (a *KafkaAdapter) Stream(logstream chan *router.Message)
type LogstashFields ¶
type LogstashFields struct {
Docker DockerFields `json:"docker"`
}
type LogstashMessageV0 ¶
type LogstashMessageV0 struct { Type string `json:"@type,omitempty"` Timestamp string `json:"@timestamp"` Sourcehost string `json:"@source_host"` Message string `json:"@message"` Fields LogstashFields `json:"@fields"` }
type LogstashMessageV1 ¶
type LogstashMessageV1 struct { Type string `json:"@type,omitempty"` Timestamp string `json:"@timestamp"` Sourcehost string `json:"host"` Message string `json:"message"` Fields DockerFields `json:"docker"` Logtype string `json:"logtype,omitempty"` // Only one of the following 3 is initialized and used, depending on the incoming json:logtype LogtypeAccessfields map[string]interface{} `json:"accesslog,omitempty"` LogtypeAppfields map[string]interface{} `json:"applog,omitempty"` LogtypeEventfields map[string]interface{} `json:"event,omitempty"` }
func (*LogstashMessageV1) UnmarshalDynamicJSON ¶
func (d *LogstashMessageV1) UnmarshalDynamicJSON(data []byte) error
Click to show internal directories.
Click to hide internal directories.