server

package
v3.1.3 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GoUnusedProtection__ int
View Source
var ServerGetMethodsResult_Success_DEFAULT []string

Functions

This section is empty.

Types

type Server

type Server interface {
	GetMethods(ctx context.Context) (r []string, err error)
	ClearAllFaults(ctx context.Context) (err error)
	// Parameters:
	//  - Method
	ClearFault(ctx context.Context, method string) (err error)
	// Parameters:
	//  - Methods
	//  - Random
	//  - ErrNo
	//  - Probability
	//  - Regexp
	//  - KillCaller
	//  - DelayUs
	//  - AutoDelay
	SetFault(ctx context.Context, methods []string, random bool, err_no int32, probability int32, regexp string, kill_caller bool, delay_us int32, auto_delay bool) (err error)
	// Parameters:
	//  - Random
	//  - ErrNo
	//  - Probability
	//  - Regexp
	//  - KillCaller
	//  - DelayUs
	//  - AutoDelay
	SetAllFault(ctx context.Context, random bool, err_no int32, probability int32, regexp string, kill_caller bool, delay_us int32, auto_delay bool) (err error)
}

type ServerClearAllFaultsArgs

type ServerClearAllFaultsArgs struct {
}

func NewServerClearAllFaultsArgs

func NewServerClearAllFaultsArgs() *ServerClearAllFaultsArgs

func (*ServerClearAllFaultsArgs) Read

func (*ServerClearAllFaultsArgs) String

func (p *ServerClearAllFaultsArgs) String() string

func (*ServerClearAllFaultsArgs) Write

type ServerClearAllFaultsResult

type ServerClearAllFaultsResult struct {
}

func NewServerClearAllFaultsResult

func NewServerClearAllFaultsResult() *ServerClearAllFaultsResult

func (*ServerClearAllFaultsResult) Read

func (*ServerClearAllFaultsResult) String

func (p *ServerClearAllFaultsResult) String() string

func (*ServerClearAllFaultsResult) Write

type ServerClearFaultArgs

type ServerClearFaultArgs struct {
	Method string
}

Attributes:

  • Method

func NewServerClearFaultArgs

func NewServerClearFaultArgs() *ServerClearFaultArgs

func (*ServerClearFaultArgs) GetMethod

func (p *ServerClearFaultArgs) GetMethod() string

func (*ServerClearFaultArgs) Read

func (p *ServerClearFaultArgs) Read(iprot thrift.TProtocol) error

func (*ServerClearFaultArgs) ReadField_1

func (p *ServerClearFaultArgs) ReadField_1(iprot thrift.TProtocol) error

func (*ServerClearFaultArgs) String

func (p *ServerClearFaultArgs) String() string

func (*ServerClearFaultArgs) Write

func (p *ServerClearFaultArgs) Write(oprot thrift.TProtocol) error

type ServerClearFaultResult

type ServerClearFaultResult struct {
}

func NewServerClearFaultResult

func NewServerClearFaultResult() *ServerClearFaultResult

func (*ServerClearFaultResult) Read

func (*ServerClearFaultResult) String

func (p *ServerClearFaultResult) String() string

func (*ServerClearFaultResult) Write

func (p *ServerClearFaultResult) Write(oprot thrift.TProtocol) error

type ServerClient

type ServerClient struct {
	// contains filtered or unexported fields
}

func Connect

Connect connects to the specified server

func NewServerClient

func NewServerClient(c thrift.TClient) *ServerClient

func NewServerClientFactory deprecated

func NewServerClientFactory(t thrift.TTransport, f thrift.TProtocolFactory) *ServerClient

Deprecated: Use NewServer instead

func NewServerClientProtocol deprecated

func NewServerClientProtocol(t thrift.TTransport, iprot thrift.TProtocol, oprot thrift.TProtocol) *ServerClient

Deprecated: Use NewServer instead

func (*ServerClient) ClearAllFaults

func (p *ServerClient) ClearAllFaults(ctx context.Context) (err error)

func (*ServerClient) ClearFault

func (p *ServerClient) ClearFault(ctx context.Context, method string) (err error)

Parameters:

  • Method

func (*ServerClient) GetMethods

func (p *ServerClient) GetMethods(ctx context.Context) (r []string, err error)

func (*ServerClient) SetAllFault

func (p *ServerClient) SetAllFault(ctx context.Context, random bool, err_no int32, probability int32, regexp string, kill_caller bool, delay_us int32, auto_delay bool) (err error)

Parameters:

  • Random
  • ErrNo
  • Probability
  • Regexp
  • KillCaller
  • DelayUs
  • AutoDelay

func (*ServerClient) SetFault

func (p *ServerClient) SetFault(ctx context.Context, methods []string, random bool, err_no int32, probability int32, regexp string, kill_caller bool, delay_us int32, auto_delay bool) (err error)

Parameters:

  • Methods
  • Random
  • ErrNo
  • Probability
  • Regexp
  • KillCaller
  • DelayUs
  • AutoDelay

type ServerGetMethodsArgs

type ServerGetMethodsArgs struct {
}

func NewServerGetMethodsArgs

func NewServerGetMethodsArgs() *ServerGetMethodsArgs

func (*ServerGetMethodsArgs) Read

func (p *ServerGetMethodsArgs) Read(iprot thrift.TProtocol) error

func (*ServerGetMethodsArgs) String

func (p *ServerGetMethodsArgs) String() string

func (*ServerGetMethodsArgs) Write

func (p *ServerGetMethodsArgs) Write(oprot thrift.TProtocol) error

type ServerGetMethodsResult

type ServerGetMethodsResult struct {
	Success []string `thrift:"success,0" db:"success" json:"success,omitempty"`
}

Attributes:

  • Success

func NewServerGetMethodsResult

func NewServerGetMethodsResult() *ServerGetMethodsResult

func (*ServerGetMethodsResult) GetSuccess

func (p *ServerGetMethodsResult) GetSuccess() []string

func (*ServerGetMethodsResult) IsSetSuccess

func (p *ServerGetMethodsResult) IsSetSuccess() bool

func (*ServerGetMethodsResult) Read

func (*ServerGetMethodsResult) ReadField0

func (p *ServerGetMethodsResult) ReadField0(iprot thrift.TProtocol) error

func (*ServerGetMethodsResult) String

func (p *ServerGetMethodsResult) String() string

func (*ServerGetMethodsResult) Write

func (p *ServerGetMethodsResult) Write(oprot thrift.TProtocol) error

type ServerProcessor

type ServerProcessor struct {
	// contains filtered or unexported fields
}

func NewServerProcessor

func NewServerProcessor(handler Server) *ServerProcessor

func (*ServerProcessor) AddToProcessorMap

func (p *ServerProcessor) AddToProcessorMap(key string, processor thrift.TProcessorFunction)

func (*ServerProcessor) GetProcessorFunction

func (p *ServerProcessor) GetProcessorFunction(key string) (processor thrift.TProcessorFunction, ok bool)

func (*ServerProcessor) Process

func (p *ServerProcessor) Process(ctx context.Context, iprot, oprot thrift.TProtocol) (success bool, err thrift.TException)

func (*ServerProcessor) ProcessorMap

func (p *ServerProcessor) ProcessorMap() map[string]thrift.TProcessorFunction

type ServerSetAllFaultArgs

type ServerSetAllFaultArgs struct {
	Random      bool
	ErrNo       int32
	Probability int32
	Regexp      string
	KillCaller  bool
	DelayUs     int32
	AutoDelay   bool
}

Attributes:

  • Random
  • ErrNo
  • Probability
  • Regexp
  • KillCaller
  • DelayUs
  • AutoDelay

func NewServerSetAllFaultArgs

func NewServerSetAllFaultArgs() *ServerSetAllFaultArgs

func (*ServerSetAllFaultArgs) GetAutoDelay

func (p *ServerSetAllFaultArgs) GetAutoDelay() bool

func (*ServerSetAllFaultArgs) GetDelayUs

func (p *ServerSetAllFaultArgs) GetDelayUs() int32

func (*ServerSetAllFaultArgs) GetErrNo

func (p *ServerSetAllFaultArgs) GetErrNo() int32

func (*ServerSetAllFaultArgs) GetKillCaller

func (p *ServerSetAllFaultArgs) GetKillCaller() bool

func (*ServerSetAllFaultArgs) GetProbability

func (p *ServerSetAllFaultArgs) GetProbability() int32

func (*ServerSetAllFaultArgs) GetRandom

func (p *ServerSetAllFaultArgs) GetRandom() bool

func (*ServerSetAllFaultArgs) GetRegexp

func (p *ServerSetAllFaultArgs) GetRegexp() string

func (*ServerSetAllFaultArgs) Read

func (*ServerSetAllFaultArgs) ReadField_1

func (p *ServerSetAllFaultArgs) ReadField_1(iprot thrift.TProtocol) error

func (*ServerSetAllFaultArgs) ReadField_2

func (p *ServerSetAllFaultArgs) ReadField_2(iprot thrift.TProtocol) error

func (*ServerSetAllFaultArgs) ReadField_3

func (p *ServerSetAllFaultArgs) ReadField_3(iprot thrift.TProtocol) error

func (*ServerSetAllFaultArgs) ReadField_4

func (p *ServerSetAllFaultArgs) ReadField_4(iprot thrift.TProtocol) error

func (*ServerSetAllFaultArgs) ReadField_5

func (p *ServerSetAllFaultArgs) ReadField_5(iprot thrift.TProtocol) error

func (*ServerSetAllFaultArgs) ReadField_6

func (p *ServerSetAllFaultArgs) ReadField_6(iprot thrift.TProtocol) error

func (*ServerSetAllFaultArgs) ReadField_7

func (p *ServerSetAllFaultArgs) ReadField_7(iprot thrift.TProtocol) error

func (*ServerSetAllFaultArgs) String

func (p *ServerSetAllFaultArgs) String() string

func (*ServerSetAllFaultArgs) Write

func (p *ServerSetAllFaultArgs) Write(oprot thrift.TProtocol) error

type ServerSetAllFaultResult

type ServerSetAllFaultResult struct {
}

func NewServerSetAllFaultResult

func NewServerSetAllFaultResult() *ServerSetAllFaultResult

func (*ServerSetAllFaultResult) Read

func (*ServerSetAllFaultResult) String

func (p *ServerSetAllFaultResult) String() string

func (*ServerSetAllFaultResult) Write

type ServerSetFaultArgs

type ServerSetFaultArgs struct {
	Methods     []string
	Random      bool
	ErrNo       int32
	Probability int32
	Regexp      string
	KillCaller  bool
	DelayUs     int32
	AutoDelay   bool
}

Attributes:

  • Methods
  • Random
  • ErrNo
  • Probability
  • Regexp
  • KillCaller
  • DelayUs
  • AutoDelay

func NewServerSetFaultArgs

func NewServerSetFaultArgs() *ServerSetFaultArgs

func (*ServerSetFaultArgs) GetAutoDelay

func (p *ServerSetFaultArgs) GetAutoDelay() bool

func (*ServerSetFaultArgs) GetDelayUs

func (p *ServerSetFaultArgs) GetDelayUs() int32

func (*ServerSetFaultArgs) GetErrNo

func (p *ServerSetFaultArgs) GetErrNo() int32

func (*ServerSetFaultArgs) GetKillCaller

func (p *ServerSetFaultArgs) GetKillCaller() bool

func (*ServerSetFaultArgs) GetMethods

func (p *ServerSetFaultArgs) GetMethods() []string

func (*ServerSetFaultArgs) GetProbability

func (p *ServerSetFaultArgs) GetProbability() int32

func (*ServerSetFaultArgs) GetRandom

func (p *ServerSetFaultArgs) GetRandom() bool

func (*ServerSetFaultArgs) GetRegexp

func (p *ServerSetFaultArgs) GetRegexp() string

func (*ServerSetFaultArgs) Read

func (p *ServerSetFaultArgs) Read(iprot thrift.TProtocol) error

func (*ServerSetFaultArgs) ReadField_1

func (p *ServerSetFaultArgs) ReadField_1(iprot thrift.TProtocol) error

func (*ServerSetFaultArgs) ReadField_2

func (p *ServerSetFaultArgs) ReadField_2(iprot thrift.TProtocol) error

func (*ServerSetFaultArgs) ReadField_3

func (p *ServerSetFaultArgs) ReadField_3(iprot thrift.TProtocol) error

func (*ServerSetFaultArgs) ReadField_4

func (p *ServerSetFaultArgs) ReadField_4(iprot thrift.TProtocol) error

func (*ServerSetFaultArgs) ReadField_5

func (p *ServerSetFaultArgs) ReadField_5(iprot thrift.TProtocol) error

func (*ServerSetFaultArgs) ReadField_6

func (p *ServerSetFaultArgs) ReadField_6(iprot thrift.TProtocol) error

func (*ServerSetFaultArgs) ReadField_7

func (p *ServerSetFaultArgs) ReadField_7(iprot thrift.TProtocol) error

func (*ServerSetFaultArgs) ReadField_8

func (p *ServerSetFaultArgs) ReadField_8(iprot thrift.TProtocol) error

func (*ServerSetFaultArgs) String

func (p *ServerSetFaultArgs) String() string

func (*ServerSetFaultArgs) Write

func (p *ServerSetFaultArgs) Write(oprot thrift.TProtocol) error

type ServerSetFaultResult

type ServerSetFaultResult struct {
}

func NewServerSetFaultResult

func NewServerSetFaultResult() *ServerSetFaultResult

func (*ServerSetFaultResult) Read

func (p *ServerSetFaultResult) Read(iprot thrift.TProtocol) error

func (*ServerSetFaultResult) String

func (p *ServerSetFaultResult) String() string

func (*ServerSetFaultResult) Write

func (p *ServerSetFaultResult) Write(oprot thrift.TProtocol) error

Jump to

Keyboard shortcuts

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