request

package
v0.5.19-b3 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2022 License: Apache-2.0 Imports: 4 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type File

type File struct {
	//FieldName string
	//if len(FileBytes)>0 will use FileBytes as filestream
	File      *os.File
	FileName  string
	FileBytes []byte
}

type LbOptions

type LbOptions struct {
	MaxRetriesOnNextServiceInstance int
	RetryableStatusCodes            []int
	Enabled                         bool
	Retrys                          int
	CurrentStatuCode                int
	CurrentError                    error
}

func NewDefaultLbOptions

func NewDefaultLbOptions() *LbOptions

type Request

type Request struct {
	Url         string
	ServiceName string
	Path        string
	Headers     map[string]string
	Params      io.Reader
	IsJson      bool
	RespResult  interface{}
	TimeOut     time.Duration
	Method      string
	LbOptions   *LbOptions
	HasFile     bool
	Context     context.Context
}

func (*Request) WithContext added in v0.0.9

func (r *Request) WithContext(ctx context.Context)

Jump to

Keyboard shortcuts

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