Documentation ¶
Index ¶
- Variables
- func CloudContextFilter(r typhon.Request, s typhon.Service) typhon.Response
- func CloudContextMiddleware(h http.Handler) http.Handler
- func Trace(ctx context.Context) string
- func WithTrace(ctx context.Context, r *http.Request, projectID string) context.Context
- type Entry
- type StackDriverLogger
Constants ¶
This section is empty.
Variables ¶
View Source
var ProjectID string
Functions ¶
func CloudContextFilter ¶
CloudContextFilter adds data to the context for the Google Cloud Run environment
Types ¶
type Entry ¶
type Entry struct { Message string `json:"message"` Severity string `json:"severity,omitempty"` Trace string `json:"logging.googleapis.com/trace,omitempty"` Labels map[string]string `json:"logging.googleapis.com/labels,omitempty"` Params map[string]string `json:"params,omitempty"` }
Entry ...
type StackDriverLogger ¶
type StackDriverLogger struct {
// contains filtered or unexported fields
}
StackDriverLogger is an implementation of monzo/slog.Logger that emits stackdriver compatible events
func (*StackDriverLogger) Flush ¶
func (l *StackDriverLogger) Flush() error
func (*StackDriverLogger) Log ¶
func (l *StackDriverLogger) Log(evs ...slog.Event)
Click to show internal directories.
Click to hide internal directories.