Documentation ¶
Index ¶
- Constants
- Variables
- func NewTracer(config map[string]interface{}) (api.Tracer, error)
- type SofaRPCSpan
- func (s *SofaRPCSpan) EndTime() time.Time
- func (s *SofaRPCSpan) FinishSpan()
- func (s *SofaRPCSpan) InjectContext(requestHeaders api.HeaderMap, requestInfo api.RequestInfo)
- func (s *SofaRPCSpan) ParentSpanId() string
- func (s *SofaRPCSpan) SetOperation(operation string)
- func (s *SofaRPCSpan) SetRequestInfo(reqinfo api.RequestInfo)
- func (s *SofaRPCSpan) SetStartTime(startTime time.Time)
- func (s *SofaRPCSpan) SetTag(key uint64, value string)
- func (s *SofaRPCSpan) SpanId() string
- func (s *SofaRPCSpan) SpawnChild(operationName string, startTime time.Time) api.Span
- func (s *SofaRPCSpan) StartTime() time.Time
- func (s *SofaRPCSpan) String() string
- func (s *SofaRPCSpan) Tag(key uint64) string
- func (s *SofaRPCSpan) TraceId() string
- type Tracer
Constants ¶
View Source
const ( // old key TARGET_SERVICE_KEY = "sofa_head_target_service" // new key SERVICE_KEY = "service" TARGET_METHOD_KEY = "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_KEY = "rpc_trace_context.sofaCallerApp" 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
View Source
const ( TRACE_ID = iota SPAN_ID PARENT_SPAN_ID SERVICE_NAME METHOD_NAME PROTOCOL RESULT_STATUS REQUEST_SIZE RESPONSE_SIZE UPSTREAM_HOST_ADDRESS DOWNSTEAM_HOST_ADDRESS CALLER_APP_NAME //caller TARGET_APP_NAME //remote app SPAN_TYPE BAGGAGE_DATA REQUEST_URL TARGET_CELL TARGET_IDC TARGET_CITY ROUTE_RECORD CALLER_CELL TRACE_END = 70 )
View Source
const ( MOSN_PROCESS_TIME = 60 + iota MOSN_TLS_STATE TLSCipherSuite MOSN_PROCESS_FAIL )
Variables ¶
View Source
var PrintLog = true
Functions ¶
Types ¶
type SofaRPCSpan ¶ added in v0.26.0
type SofaRPCSpan struct {
// contains filtered or unexported fields
}
func (*SofaRPCSpan) EndTime ¶ added in v0.26.0
func (s *SofaRPCSpan) EndTime() time.Time
func (*SofaRPCSpan) FinishSpan ¶ added in v0.26.0
func (s *SofaRPCSpan) FinishSpan()
func (*SofaRPCSpan) InjectContext ¶ added in v0.26.0
func (s *SofaRPCSpan) InjectContext(requestHeaders api.HeaderMap, requestInfo api.RequestInfo)
func (*SofaRPCSpan) ParentSpanId ¶ added in v0.26.0
func (s *SofaRPCSpan) ParentSpanId() string
func (*SofaRPCSpan) SetOperation ¶ added in v0.26.0
func (s *SofaRPCSpan) SetOperation(operation string)
func (*SofaRPCSpan) SetRequestInfo ¶ added in v0.26.0
func (s *SofaRPCSpan) SetRequestInfo(reqinfo api.RequestInfo)
func (*SofaRPCSpan) SetStartTime ¶ added in v0.26.0
func (s *SofaRPCSpan) SetStartTime(startTime time.Time)
func (*SofaRPCSpan) SetTag ¶ added in v0.26.0
func (s *SofaRPCSpan) SetTag(key uint64, value string)
func (*SofaRPCSpan) SpanId ¶ added in v0.26.0
func (s *SofaRPCSpan) SpanId() string
func (*SofaRPCSpan) SpawnChild ¶ added in v0.26.0
func (*SofaRPCSpan) StartTime ¶ added in v0.26.0
func (s *SofaRPCSpan) StartTime() time.Time
func (*SofaRPCSpan) String ¶ added in v0.26.0
func (s *SofaRPCSpan) String() string
func (*SofaRPCSpan) Tag ¶ added in v0.26.0
func (s *SofaRPCSpan) Tag(key uint64) string
func (*SofaRPCSpan) TraceId ¶ added in v0.26.0
func (s *SofaRPCSpan) TraceId() string
Click to show internal directories.
Click to hide internal directories.