Documentation
¶
Overview ¶
Package stackdriver send log lines to Google Stackdriver.
It is based on https://godoc.org/cloud.google.com/go/logging
Index ¶
Constants ¶
View Source
const (
Name = "stackdriver"
)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct { // A Parent can take any of the following forms: // // - projects/PROJECT_ID // - folders/FOLDER_ID // - billingAccounts/ACCOUNT_ID // - organizations/ORG_ID // // for backwards compatibility, a string with no '/' is also allowed and is // interpreted as a project ID. // ProjectID sets the Google Cloud Platform project ID. Parent string `toml:"parent"` // Name sets the name of the log to write to. // // A log ID must be less than 512 characters long and can only // include the following characters: upper and lower case alphanumeric // characters: [A-Za-z0-9]; and punctuation characters: forward-slash, // underscore, hyphen, and period. LogID string `toml:"log_id"` // FlushPeriod is the frequence on which log lines are flushed to StackDriver FlushPeriod int `toml:"flush_period"` // CommonLabels are labels that apply to all log entries written from a Logger, // so that you don't have to repeat them in each log entry's Labels field. If // any of the log entries contains a (key, value) with the same key that is in // CommonLabels, then the entry's (key, value) overrides the one in // CommonLabels. CommonLabels map[string]string `toml:"common_labels"` // Credentials allows to define authentication credentials from the config // file instead of the GOOGLE_APPLICATION_CREDENTIALS environment variable. Credentials ConfigCredentials `toml:"credentials"` }
Config defines the filer printer config
type ConfigCredentials ¶ added in v1.0.0
type ConfigCredentials struct { Type string `json:"type" toml:"type"` ProjectID string `json:"project_id" toml:"project_id"` PrivateKeyID string `json:"private_key_id" toml:"private_key_id"` PrivateKey string `json:"private_key" toml:"private_key"` ClientEmail string `json:"client_email" toml:"client_email"` ClientID string `json:"client_id" toml:"client_id"` AuthURI string `json:"auth_uri" toml:"auth_uri"` TokenURI string `json:"token_uri" toml:"token_uri"` AuthProviderX509CertURL string `json:"auth_provider_x509_cert_url" toml:"auth_provider_x509_cert_url"` ClientX509CertURL string `json:"client_x509_cert_url" toml:"client_x509_cert_url"` }
Click to show internal directories.
Click to hide internal directories.