Documentation
¶
Index ¶
- Constants
- func Get(key string, c *app.RequestContext) (val any, found bool)
- func GetBool(key string, c *app.RequestContext) bool
- func GetFloat32(key string, c *app.RequestContext) float32
- func GetFloat64(key string, c *app.RequestContext) float64
- func GetInt32(key string, c *app.RequestContext) int32
- func GetInt64(key string, c *app.RequestContext) int64
- func GetString(key string, c *app.RequestContext) string
- func GetTime(key string, c *app.RequestContext) time.Time
- func IsDirective(key string) bool
- func ParseDirectives(content string) []string
- type RequestOriginal
- type RequestRoute
Constants ¶
View Source
const ( Time = "$time" ServerID = "$server_id" RouteID = "$route_id" ServiceID = "$service_id" UpstreamID = "$upstream_id" RequestOrig = "$request_orig" NetworkPeerAddress = "$network.peer.address" Hostname = "$hostname" TraceID = "$trace_id" HTTPStart = "$http.start" HTTPFinish = "$http.finish" HTTPRoute = "$http.route" HTTPRequest = "$http.request" HTTPRequestSize = "$http.request.size" HTTPRequestScheme = "$http.request.scheme" HTTPRequestHost = "$http.request.host" HTTPRequestMethod = "$http.request.method" HTTPRequestPath = "$http.request.path" HTTPRequestQuery = "$http.request.query" HTTPRequestProtocol = "$http.request.protocol" HTTPRequestURI = "$http.request.uri" HTTPRequestBody = "$http.request.body" HTTPResponseSize = "$http.response.size" HTTPResponseStatusCode = "$http.response.status_code" HTTPRequestDuration = "$http.request.duration" ErrorType = "$error.type" ErrorMessage = "$error.message" LogTime = "$log_time" UpstreamRequest = "$upstream.request" UpstreamRequestHost = "$upstream.request.host" UpstreamRequestMethod = "$upstream.request.method" UpstreamRequestPath = "$upstream.request.path" UpstreamRequestQuery = "$upstream.request.query" UpstreamRequestURI = "$upstream.request.uri" UpstreamRequestProtocol = "$upstream.request.protocol" UpstreamDuration = "$upstream.duration" UpstreamResponoseStatusCode = "$upstream.response.status_code" Allow = "$allow" ClientIP = "$client_ip" BifrostRoute = "$bifrost.route" TargetTimeout = "target_timeout" // grpc GRPCStatusCode = "$grpc.status_code" GRPCMessage = "$grpc.message" B = 1 KB = 1024 * B MB = 1024 * KB GB = 1024 * MB )
Variables ¶
This section is empty.
Functions ¶
func GetFloat32 ¶
func GetFloat32(key string, c *app.RequestContext) float32
func GetFloat64 ¶
func GetFloat64(key string, c *app.RequestContext) float64
func IsDirective ¶
func ParseDirectives ¶ added in v0.2.0
Types ¶
type RequestOriginal ¶ added in v0.2.0
type RequestRoute ¶ added in v0.2.0
Click to show internal directories.
Click to hide internal directories.