env

package
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 31, 2017 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Namespace set by the auth middleware based on the token in the request
	// Type: auth.Namespace
	Namespace = "NAMESPACE"

	// RequestID defines the unique id of the request, set by the trace middleware
	// Type: string
	RequestID = "REQUEST_ID"

	// StatusCode defines the HTTP status code, set by the rest.RecorderMiddleware
	// Type: int
	StatusCode = "STATUS_CODE"

	// BytesWritten defines the number of data bytes written to the response, set by the rest.RecorderMiddleware
	// Type: int64
	BytesWritten = "BYTES_WRITTEN"

	// StartTime defines the time when the execution of the request was started, set by the rest.TimerMiddleware
	// Type: *time.Time
	StartTime = "START_TIME"

	// ElapsedTime defines the elapsed time spent during the execution of the wrapped handler, set by the rest. TimerMiddleware
	// Type: *time.Duration
	ElapsedTime = "ELAPSED_TIME"

	// APIProtocol set by the protocol.APIHandler
	// Type: protocol.Type
	APIProtocol = "API_PROTOCOL"

	// APIOperation set by the protocol.APIHandler
	// Type: protocol.Operation
	APIOperation = "API_OPERATION"

	// ServiceInstance is the instance on which the current API operation operates upon, set by the corresponding HTTP handler.
	// Relevant only for operations targeted at a single service instance (register, deregister, heartbeat, ...).
	// Type: *store.ServiceInstance
	ServiceInstance = "SERVICE_INSTANCE"

	// Type: context.Context
	Context = "CONTEXT"
)

The following are the variables exposed by the Registry to the wrapping middlewares as request.Env[variable].(type)

Variables

This section is empty.

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL