sofa

package
v0.13.0 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2020 License: Apache-2.0 Imports: 6 Imported by: 3

Documentation

Index

Constants

View Source
const (
	// old key
	TARGET_SERVICE_KEY = "sofa_head_target_service"
	// new key
	SERVICE_KEY             = "service"
	TARGET_METHOD           = "sofa_head_method_name"
	RPC_ID_KEY              = "rpc_trace_context.sofaRpcId"
	TRACER_ID_KEY           = "rpc_trace_context.sofaTraceId"
	CALLER_IP_KEY           = "rpc_trace_context.sofaCallerIp"
	CALLER_ZONE_KEY         = "rpc_trace_context.sofaCallerZone"
	APP_NAME                = "app"
	SOFA_TRACE_BAGGAGE_DATA = "rpc_trace_context.sofaPenAttrs"
	// http key
	HTTP_RPC_ID_KEY    = "SOFA-RpcId"
	HTTP_TRACER_ID_KEY = "SOFA-TraceId"
)

Const of tracing key

Variables

View Source
var (
	ErrIngressLogger = errors.New("ingress logger cannot be empty")
	ErrEgressLogger  = errors.New("egress logger cannot be empty")
)

Functions

func GetEgressLogger

func GetEgressLogger(protocol types.ProtocolName) *log.Logger

func GetIngressLogger

func GetIngressLogger(protocol types.ProtocolName) *log.Logger

func Init

func Init(protocol types.ProtocolName, logRoot, logIngress, logEgress string) (err error)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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