http_request

package
v1.4.6 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2020 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	X_REQUEST_ID      = "x-request-id"
	X_B3_TRACEID      = "x-b3-traceid"
	X_B3_SPANID       = "x-b3-spanid"
	X_B3_PARENTSPANID = "x-b3-parentspanid"
	X_B3_SAMPLED      = "x-b3-sampled"
	X_B3_FLAGS        = "x-b3-flags"
	B3                = "b3"
	X_OT_SPAN_CONTEXT = "x-ot-span-context"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type HttpClient

type HttpClient struct {
	Client *resty.Client
	*resty.Request
}

func New

func New() HttpClient

func (HttpClient) SetTrace

func (h HttpClient) SetTrace(header interface{}) HttpClient

type TraceHeader

type TraceHeader struct {
	Http_Header http.Header
	Grpc_MD     metadata.MD
}

func SetGrpc

func SetGrpc(ctx context.Context) TraceHeader

func SetHeader

func SetHeader(header interface{}) TraceHeader

func SetHttp

func SetHttp(header http.Header) TraceHeader

Jump to

Keyboard shortcuts

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