Documentation
¶
Index ¶
- type ChainConnectionStatus
- type HealthCheck
- type InvRequestBody
- type InvRequestParams
- func (irp *InvRequestParams) AlertingDestType() core.AlertDestination
- func (irp *InvRequestParams) GeneratePipelineConfig(pollInterval time.Duration, regType core.RegisterType) *core.PipelineConfig
- func (irp *InvRequestParams) InvariantType() core.InvariantType
- func (irp *InvRequestParams) NetworkType() core.Network
- func (irp *InvRequestParams) Params() *core.InvSessionParams
- func (irp *InvRequestParams) PipelineType() core.PipelineType
- func (irp *InvRequestParams) SessionConfig() *core.SessionConfig
- type InvResponse
- type InvResponseStatus
- type InvResult
- type InvariantMethod
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChainConnectionStatus ¶
ChainConnectionStatus ... Used to display health status of each node connection
type HealthCheck ¶
type HealthCheck struct {
Timestamp time.Time
Healthy bool
ChainConnectionStatus *ChainConnectionStatus
}
HealthCheck ... Returns health status of server
type InvRequestBody ¶
type InvRequestBody struct {
Method string `json:"method"`
Params InvRequestParams `json:"params"`
}
InvRequestBody ... Request body for invariant operation request
func (*InvRequestBody) Clone ¶
func (irb *InvRequestBody) Clone() *InvRequestBody
func (*InvRequestBody) MethodType ¶
func (irb *InvRequestBody) MethodType() InvariantMethod
MethodType ... Returns the invariant method type
type InvRequestParams ¶
type InvRequestParams struct {
Network string `json:"network"`
PType string `json:"pipeline_type"`
InvType string `json:"type"`
StartHeight *big.Int `json:"start_height"`
EndHeight *big.Int `json:"end_height"`
SessionParams map[string]interface{} `json:"invariant_params"`
// TODO(#81): No Support for Multiple Alerting Destinations for an Invariant Session
AlertingDest string `json:"alert_destination"`
}
InvRequestParams ... Request params for invariant operation
func (*InvRequestParams) AlertingDestType ¶
func (irp *InvRequestParams) AlertingDestType() core.AlertDestination
AlertingDestType ... Returns the alerting destination type
func (*InvRequestParams) GeneratePipelineConfig ¶
func (irp *InvRequestParams) GeneratePipelineConfig(pollInterval time.Duration, regType core.RegisterType) *core.PipelineConfig
GeneratePipelineConfig ... Generates a pipeline config using the request params
func (*InvRequestParams) InvariantType ¶
func (irp *InvRequestParams) InvariantType() core.InvariantType
InvariantType ... Returns the invariant type
func (*InvRequestParams) NetworkType ¶
func (irp *InvRequestParams) NetworkType() core.Network
NetworkType ... Returns the network type
func (*InvRequestParams) Params ¶
func (irp *InvRequestParams) Params() *core.InvSessionParams
Params ... Returns the invariant session params
func (*InvRequestParams) PipelineType ¶
func (irp *InvRequestParams) PipelineType() core.PipelineType
PipelineType ... Returns the pipeline type
func (*InvRequestParams) SessionConfig ¶
func (irp *InvRequestParams) SessionConfig() *core.SessionConfig
SessionConfig ... Generates a session config using the request params
type InvResponse ¶
type InvResponse struct {
Code int `json:"status_code"`
Status InvResponseStatus `json:"status"`
Result InvResult `json:"result"`
Error string `json:"error"`
}
InvResponse ... Response for invariant operation request
func NewInvAcceptedResp ¶
func NewInvAcceptedResp(id core.SUUID) *InvResponse
NewInvAcceptedResp ...Returns an invariant response with status accepted
func NewInvNoProcessInvResp ¶
func NewInvNoProcessInvResp() *InvResponse
NewInvNoProcessInvResp ... New internal processing response error
func NewInvUnmarshalErrResp ¶
func NewInvUnmarshalErrResp() *InvResponse
NewInvUnmarshalErrResp ... New unmarshal error response construction
type InvResponseStatus ¶
type InvResponseStatus string
InvResponseStatus ... Represents the invariant operation response status
const ( OK InvResponseStatus = "OK" NotOK InvResponseStatus = "NOTOK" )
type InvariantMethod ¶
type InvariantMethod int
InvariantMethod ... Represents the invariant operation method
const ( Run InvariantMethod = iota // NOTE - Update is not implemented yet Update // NOTE - Stop is not implemented yet Stop )
func StringToInvariantMethod ¶
func StringToInvariantMethod(s string) InvariantMethod