Documentation
¶
Index ¶
Constants ¶
const ( AttrSessionKey = "session_key" AttrServerHost = "serverHost" AttrOrigServerHost = "__origServerHost" AttrLogFile = "logfile" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AddEventsRequest ¶
type AddEventsRequest struct { request.AuthParams AddEventsRequestParams }
AddEventsRequest represents a AddEvent DataSet REST API request.
type AddEventsRequestParams ¶
type AddEventsRequestParams struct { Session string `json:"session,omitempty"` SessionInfo *SessionInfo `json:"sessionInfo,omitempty"` Events []*Event `json:"events,omitempty"` Threads []*Thread `json:"threads,omitempty"` Logs []*Log `json:"logs,omitempty"` }
AddEventsRequestParams represents a represents a AddEvent DataSet REST API request parameters, see https://app.scalyr.com/help/api#addEvents.
type AddEventsResponse ¶
type AddEventsResponse struct { response.ApiResponse BytesCharged int64 `json:"bytesCharged"` }
AddEventsResponse represents a AddEvent DataSet REST API response.
func (*AddEventsResponse) SetResponseObj ¶
func (response *AddEventsResponse) SetResponseObj(resp *http.Response)
type Event ¶
type Event struct { Thread string `json:"thread,omitempty"` Sev int `json:"sev,omitempty"` Ts string `json:"ts,omitempty"` Log string `json:"log,omitempty"` Attrs EventAttrs `json:"attrs"` ServerHost string `json:"-"` }
Event represents DataSet REST API event structure (see https://app.scalyr.com/help/api#addEvents)
func (*Event) CloneWithoutAttrs ¶
type EventAttrs ¶ added in v0.0.10
type EventAttrs = map[string]interface{}
type EventBundle ¶
EventBundle represents a single DataSet event wrapper structure (see https://app.scalyr.com/help/api#addEvents) Event - Zero or more events (log messages) to upload. Thread - Optional. Lets you create a readable name for each thread in Event. Log - Optional. Lets you set constant metadata, whose value does not change in multiple events in the request. see also AddEventsRequest which represent full AddEvent DataSet event wrapper structure
type Log ¶
Log represents a shared attributes reused in multiple Event in EventBundle. This decreases redundant data, and improves throughput.
type SessionInfo ¶
type SessionInfo = map[string]interface{}