circuitbreakerrpc

package module
v0.0.0-...-60b70d9 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2023 License: MIT Imports: 27 Imported by: 0

Documentation

Overview

Package circuitbreakerrpc is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

This section is empty.

Variables

View Source
var (
	Mode_name = map[int32]string{
		0: "MODE_FAIL",
		1: "MODE_QUEUE",
		2: "MODE_QUEUE_PEER_INITIATED",
		3: "MODE_BLOCK",
	}
	Mode_value = map[string]int32{
		"MODE_FAIL":                 0,
		"MODE_QUEUE":                1,
		"MODE_QUEUE_PEER_INITIATED": 2,
		"MODE_BLOCK":                3,
	}
)

Enum value maps for Mode.

View Source
var File_circuitbreaker_proto protoreflect.FileDescriptor
View Source
var Service_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "circuitbreaker.Service",
	HandlerType: (*ServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GetInfo",
			Handler:    _Service_GetInfo_Handler,
		},
		{
			MethodName: "UpdateLimits",
			Handler:    _Service_UpdateLimits_Handler,
		},
		{
			MethodName: "ClearLimits",
			Handler:    _Service_ClearLimits_Handler,
		},
		{
			MethodName: "UpdateDefaultLimit",
			Handler:    _Service_UpdateDefaultLimit_Handler,
		},
		{
			MethodName: "ListLimits",
			Handler:    _Service_ListLimits_Handler,
		},
		{
			MethodName: "ListForwardingHistory",
			Handler:    _Service_ListForwardingHistory_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "circuitbreaker.proto",
}

Service_ServiceDesc is the grpc.ServiceDesc for Service service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterServiceHandler

func RegisterServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterServiceHandler registers the http handlers for service Service to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterServiceHandlerClient

func RegisterServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ServiceClient) error

RegisterServiceHandlerClient registers the http handlers for service Service to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "ServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "ServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "ServiceClient" to call the correct interceptors.

func RegisterServiceHandlerFromEndpoint

func RegisterServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterServiceHandlerFromEndpoint is same as RegisterServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterServiceHandlerServer

func RegisterServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ServiceServer) error

RegisterServiceHandlerServer registers the http handlers for service Service to "mux". UnaryRPC :call ServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterServiceHandlerFromEndpoint instead.

func RegisterServiceServer

func RegisterServiceServer(s grpc.ServiceRegistrar, srv ServiceServer)

Types

type CircuitKey

type CircuitKey struct {
	ShortChannelId uint64 `protobuf:"varint,1,opt,name=short_channel_id,json=shortChannelId,proto3" json:"short_channel_id,omitempty"`
	HtlcIndex      uint32 `protobuf:"varint,2,opt,name=htlc_index,json=htlcIndex,proto3" json:"htlc_index,omitempty"`
	// contains filtered or unexported fields
}

func (*CircuitKey) Descriptor deprecated

func (*CircuitKey) Descriptor() ([]byte, []int)

Deprecated: Use CircuitKey.ProtoReflect.Descriptor instead.

func (*CircuitKey) GetHtlcIndex

func (x *CircuitKey) GetHtlcIndex() uint32

func (*CircuitKey) GetShortChannelId

func (x *CircuitKey) GetShortChannelId() uint64

func (*CircuitKey) ProtoMessage

func (*CircuitKey) ProtoMessage()

func (*CircuitKey) ProtoReflect

func (x *CircuitKey) ProtoReflect() protoreflect.Message

func (*CircuitKey) Reset

func (x *CircuitKey) Reset()

func (*CircuitKey) String

func (x *CircuitKey) String() string

func (*CircuitKey) Validate

func (m *CircuitKey) Validate() error

Validate checks the field values on CircuitKey with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type CircuitKeyValidationError

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

CircuitKeyValidationError is the validation error returned by CircuitKey.Validate if the designated constraints aren't met.

func (CircuitKeyValidationError) Cause

func (e CircuitKeyValidationError) Cause() error

Cause function returns cause value.

func (CircuitKeyValidationError) Error

Error satisfies the builtin error interface

func (CircuitKeyValidationError) ErrorName

func (e CircuitKeyValidationError) ErrorName() string

ErrorName returns error name.

func (CircuitKeyValidationError) Field

Field function returns field value.

func (CircuitKeyValidationError) Key

Key function returns key value.

func (CircuitKeyValidationError) Reason

func (e CircuitKeyValidationError) Reason() string

Reason function returns reason value.

type ClearLimitsRequest

type ClearLimitsRequest struct {
	Nodes []string `protobuf:"bytes,1,rep,name=nodes,proto3" json:"nodes,omitempty"`
	// contains filtered or unexported fields
}

func (*ClearLimitsRequest) Descriptor deprecated

func (*ClearLimitsRequest) Descriptor() ([]byte, []int)

Deprecated: Use ClearLimitsRequest.ProtoReflect.Descriptor instead.

func (*ClearLimitsRequest) GetNodes

func (x *ClearLimitsRequest) GetNodes() []string

func (*ClearLimitsRequest) ProtoMessage

func (*ClearLimitsRequest) ProtoMessage()

func (*ClearLimitsRequest) ProtoReflect

func (x *ClearLimitsRequest) ProtoReflect() protoreflect.Message

func (*ClearLimitsRequest) Reset

func (x *ClearLimitsRequest) Reset()

func (*ClearLimitsRequest) String

func (x *ClearLimitsRequest) String() string

func (*ClearLimitsRequest) Validate

func (m *ClearLimitsRequest) Validate() error

Validate checks the field values on ClearLimitsRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type ClearLimitsRequestValidationError

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

ClearLimitsRequestValidationError is the validation error returned by ClearLimitsRequest.Validate if the designated constraints aren't met.

func (ClearLimitsRequestValidationError) Cause

Cause function returns cause value.

func (ClearLimitsRequestValidationError) Error

Error satisfies the builtin error interface

func (ClearLimitsRequestValidationError) ErrorName

ErrorName returns error name.

func (ClearLimitsRequestValidationError) Field

Field function returns field value.

func (ClearLimitsRequestValidationError) Key

Key function returns key value.

func (ClearLimitsRequestValidationError) Reason

Reason function returns reason value.

type ClearLimitsResponse

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

func (*ClearLimitsResponse) Descriptor deprecated

func (*ClearLimitsResponse) Descriptor() ([]byte, []int)

Deprecated: Use ClearLimitsResponse.ProtoReflect.Descriptor instead.

func (*ClearLimitsResponse) ProtoMessage

func (*ClearLimitsResponse) ProtoMessage()

func (*ClearLimitsResponse) ProtoReflect

func (x *ClearLimitsResponse) ProtoReflect() protoreflect.Message

func (*ClearLimitsResponse) Reset

func (x *ClearLimitsResponse) Reset()

func (*ClearLimitsResponse) String

func (x *ClearLimitsResponse) String() string

func (*ClearLimitsResponse) Validate

func (m *ClearLimitsResponse) Validate() error

Validate checks the field values on ClearLimitsResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type ClearLimitsResponseValidationError

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

ClearLimitsResponseValidationError is the validation error returned by ClearLimitsResponse.Validate if the designated constraints aren't met.

func (ClearLimitsResponseValidationError) Cause

Cause function returns cause value.

func (ClearLimitsResponseValidationError) Error

Error satisfies the builtin error interface

func (ClearLimitsResponseValidationError) ErrorName

ErrorName returns error name.

func (ClearLimitsResponseValidationError) Field

Field function returns field value.

func (ClearLimitsResponseValidationError) Key

Key function returns key value.

func (ClearLimitsResponseValidationError) Reason

Reason function returns reason value.

type Counter

type Counter struct {
	Fail    int64 `protobuf:"varint,1,opt,name=fail,proto3" json:"fail,omitempty"`
	Success int64 `protobuf:"varint,2,opt,name=success,proto3" json:"success,omitempty"`
	Reject  int64 `protobuf:"varint,3,opt,name=reject,proto3" json:"reject,omitempty"`
	// contains filtered or unexported fields
}

func (*Counter) Descriptor deprecated

func (*Counter) Descriptor() ([]byte, []int)

Deprecated: Use Counter.ProtoReflect.Descriptor instead.

func (*Counter) GetFail

func (x *Counter) GetFail() int64

func (*Counter) GetReject

func (x *Counter) GetReject() int64

func (*Counter) GetSuccess

func (x *Counter) GetSuccess() int64

func (*Counter) ProtoMessage

func (*Counter) ProtoMessage()

func (*Counter) ProtoReflect

func (x *Counter) ProtoReflect() protoreflect.Message

func (*Counter) Reset

func (x *Counter) Reset()

func (*Counter) String

func (x *Counter) String() string

func (*Counter) Validate

func (m *Counter) Validate() error

Validate checks the field values on Counter with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type CounterValidationError

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

CounterValidationError is the validation error returned by Counter.Validate if the designated constraints aren't met.

func (CounterValidationError) Cause

func (e CounterValidationError) Cause() error

Cause function returns cause value.

func (CounterValidationError) Error

func (e CounterValidationError) Error() string

Error satisfies the builtin error interface

func (CounterValidationError) ErrorName

func (e CounterValidationError) ErrorName() string

ErrorName returns error name.

func (CounterValidationError) Field

func (e CounterValidationError) Field() string

Field function returns field value.

func (CounterValidationError) Key

func (e CounterValidationError) Key() bool

Key function returns key value.

func (CounterValidationError) Reason

func (e CounterValidationError) Reason() string

Reason function returns reason value.

type Forward

type Forward struct {

	// The time that the htlc was added to the incoming channel. Note that this value
	// may be zero if circuitbreaker restarted while the htlc was in flight - this
	// indicates that the value is unknown.
	AddTimeNs       uint64      `protobuf:"varint,1,opt,name=add_time_ns,json=addTimeNs,proto3" json:"add_time_ns,omitempty"`
	ResolveTimeNs   uint64      `protobuf:"varint,2,opt,name=resolve_time_ns,json=resolveTimeNs,proto3" json:"resolve_time_ns,omitempty"`
	Settled         bool        `protobuf:"varint,3,opt,name=settled,proto3" json:"settled,omitempty"`
	IncomingAmount  uint64      `protobuf:"varint,4,opt,name=incoming_amount,json=incomingAmount,proto3" json:"incoming_amount,omitempty"`
	OutgoingAmount  uint64      `protobuf:"varint,5,opt,name=outgoing_amount,json=outgoingAmount,proto3" json:"outgoing_amount,omitempty"`
	IncomingPeer    string      `protobuf:"bytes,6,opt,name=incoming_peer,json=incomingPeer,proto3" json:"incoming_peer,omitempty"`
	IncomingCircuit *CircuitKey `protobuf:"bytes,7,opt,name=incoming_circuit,json=incomingCircuit,proto3" json:"incoming_circuit,omitempty"`
	OutgoingPeer    string      `protobuf:"bytes,8,opt,name=outgoing_peer,json=outgoingPeer,proto3" json:"outgoing_peer,omitempty"`
	OutgoingCircuit *CircuitKey `protobuf:"bytes,9,opt,name=outgoing_circuit,json=outgoingCircuit,proto3" json:"outgoing_circuit,omitempty"`
	// contains filtered or unexported fields
}

func (*Forward) Descriptor deprecated

func (*Forward) Descriptor() ([]byte, []int)

Deprecated: Use Forward.ProtoReflect.Descriptor instead.

func (*Forward) GetAddTimeNs

func (x *Forward) GetAddTimeNs() uint64

func (*Forward) GetIncomingAmount

func (x *Forward) GetIncomingAmount() uint64

func (*Forward) GetIncomingCircuit

func (x *Forward) GetIncomingCircuit() *CircuitKey

func (*Forward) GetIncomingPeer

func (x *Forward) GetIncomingPeer() string

func (*Forward) GetOutgoingAmount

func (x *Forward) GetOutgoingAmount() uint64

func (*Forward) GetOutgoingCircuit

func (x *Forward) GetOutgoingCircuit() *CircuitKey

func (*Forward) GetOutgoingPeer

func (x *Forward) GetOutgoingPeer() string

func (*Forward) GetResolveTimeNs

func (x *Forward) GetResolveTimeNs() uint64

func (*Forward) GetSettled

func (x *Forward) GetSettled() bool

func (*Forward) ProtoMessage

func (*Forward) ProtoMessage()

func (*Forward) ProtoReflect

func (x *Forward) ProtoReflect() protoreflect.Message

func (*Forward) Reset

func (x *Forward) Reset()

func (*Forward) String

func (x *Forward) String() string

func (*Forward) Validate

func (m *Forward) Validate() error

Validate checks the field values on Forward with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type ForwardValidationError

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

ForwardValidationError is the validation error returned by Forward.Validate if the designated constraints aren't met.

func (ForwardValidationError) Cause

func (e ForwardValidationError) Cause() error

Cause function returns cause value.

func (ForwardValidationError) Error

func (e ForwardValidationError) Error() string

Error satisfies the builtin error interface

func (ForwardValidationError) ErrorName

func (e ForwardValidationError) ErrorName() string

ErrorName returns error name.

func (ForwardValidationError) Field

func (e ForwardValidationError) Field() string

Field function returns field value.

func (ForwardValidationError) Key

func (e ForwardValidationError) Key() bool

Key function returns key value.

func (ForwardValidationError) Reason

func (e ForwardValidationError) Reason() string

Reason function returns reason value.

type GetInfoRequest

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

func (*GetInfoRequest) Descriptor deprecated

func (*GetInfoRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetInfoRequest.ProtoReflect.Descriptor instead.

func (*GetInfoRequest) ProtoMessage

func (*GetInfoRequest) ProtoMessage()

func (*GetInfoRequest) ProtoReflect

func (x *GetInfoRequest) ProtoReflect() protoreflect.Message

func (*GetInfoRequest) Reset

func (x *GetInfoRequest) Reset()

func (*GetInfoRequest) String

func (x *GetInfoRequest) String() string

func (*GetInfoRequest) Validate

func (m *GetInfoRequest) Validate() error

Validate checks the field values on GetInfoRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type GetInfoRequestValidationError

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

GetInfoRequestValidationError is the validation error returned by GetInfoRequest.Validate if the designated constraints aren't met.

func (GetInfoRequestValidationError) Cause

Cause function returns cause value.

func (GetInfoRequestValidationError) Error

Error satisfies the builtin error interface

func (GetInfoRequestValidationError) ErrorName

func (e GetInfoRequestValidationError) ErrorName() string

ErrorName returns error name.

func (GetInfoRequestValidationError) Field

Field function returns field value.

func (GetInfoRequestValidationError) Key

Key function returns key value.

func (GetInfoRequestValidationError) Reason

Reason function returns reason value.

type GetInfoResponse

type GetInfoResponse struct {
	NodeKey     string `protobuf:"bytes,1,opt,name=node_key,json=nodeKey,proto3" json:"node_key,omitempty"`
	NodeAlias   string `protobuf:"bytes,2,opt,name=node_alias,json=nodeAlias,proto3" json:"node_alias,omitempty"`
	NodeVersion string `protobuf:"bytes,3,opt,name=node_version,json=nodeVersion,proto3" json:"node_version,omitempty"`
	Version     string `protobuf:"bytes,4,opt,name=version,proto3" json:"version,omitempty"`
	// contains filtered or unexported fields
}

func (*GetInfoResponse) Descriptor deprecated

func (*GetInfoResponse) Descriptor() ([]byte, []int)

Deprecated: Use GetInfoResponse.ProtoReflect.Descriptor instead.

func (*GetInfoResponse) GetNodeAlias

func (x *GetInfoResponse) GetNodeAlias() string

func (*GetInfoResponse) GetNodeKey

func (x *GetInfoResponse) GetNodeKey() string

func (*GetInfoResponse) GetNodeVersion

func (x *GetInfoResponse) GetNodeVersion() string

func (*GetInfoResponse) GetVersion

func (x *GetInfoResponse) GetVersion() string

func (*GetInfoResponse) ProtoMessage

func (*GetInfoResponse) ProtoMessage()

func (*GetInfoResponse) ProtoReflect

func (x *GetInfoResponse) ProtoReflect() protoreflect.Message

func (*GetInfoResponse) Reset

func (x *GetInfoResponse) Reset()

func (*GetInfoResponse) String

func (x *GetInfoResponse) String() string

func (*GetInfoResponse) Validate

func (m *GetInfoResponse) Validate() error

Validate checks the field values on GetInfoResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type GetInfoResponseValidationError

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

GetInfoResponseValidationError is the validation error returned by GetInfoResponse.Validate if the designated constraints aren't met.

func (GetInfoResponseValidationError) Cause

Cause function returns cause value.

func (GetInfoResponseValidationError) Error

Error satisfies the builtin error interface

func (GetInfoResponseValidationError) ErrorName

func (e GetInfoResponseValidationError) ErrorName() string

ErrorName returns error name.

func (GetInfoResponseValidationError) Field

Field function returns field value.

func (GetInfoResponseValidationError) Key

Key function returns key value.

func (GetInfoResponseValidationError) Reason

Reason function returns reason value.

type Limit

type Limit struct {
	MaxHourlyRate int64 `protobuf:"varint,3,opt,name=max_hourly_rate,json=maxHourlyRate,proto3" json:"max_hourly_rate,omitempty"`
	MaxPending    int64 `protobuf:"varint,5,opt,name=max_pending,json=maxPending,proto3" json:"max_pending,omitempty"`
	Mode          Mode  `protobuf:"varint,6,opt,name=mode,proto3,enum=circuitbreaker.Mode" json:"mode,omitempty"`
	// contains filtered or unexported fields
}

func (*Limit) Descriptor deprecated

func (*Limit) Descriptor() ([]byte, []int)

Deprecated: Use Limit.ProtoReflect.Descriptor instead.

func (*Limit) GetMaxHourlyRate

func (x *Limit) GetMaxHourlyRate() int64

func (*Limit) GetMaxPending

func (x *Limit) GetMaxPending() int64

func (*Limit) GetMode

func (x *Limit) GetMode() Mode

func (*Limit) ProtoMessage

func (*Limit) ProtoMessage()

func (*Limit) ProtoReflect

func (x *Limit) ProtoReflect() protoreflect.Message

func (*Limit) Reset

func (x *Limit) Reset()

func (*Limit) String

func (x *Limit) String() string

func (*Limit) Validate

func (m *Limit) Validate() error

Validate checks the field values on Limit with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type LimitValidationError

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

LimitValidationError is the validation error returned by Limit.Validate if the designated constraints aren't met.

func (LimitValidationError) Cause

func (e LimitValidationError) Cause() error

Cause function returns cause value.

func (LimitValidationError) Error

func (e LimitValidationError) Error() string

Error satisfies the builtin error interface

func (LimitValidationError) ErrorName

func (e LimitValidationError) ErrorName() string

ErrorName returns error name.

func (LimitValidationError) Field

func (e LimitValidationError) Field() string

Field function returns field value.

func (LimitValidationError) Key

func (e LimitValidationError) Key() bool

Key function returns key value.

func (LimitValidationError) Reason

func (e LimitValidationError) Reason() string

Reason function returns reason value.

type ListForwardingHistoryRequest

type ListForwardingHistoryRequest struct {

	// The inclusive start time for the query, used to filter HTLCs by the time they were added
	// to local incoming channel. If this value is zero, it will be treated as the unix epoch.
	AddStartTimeNs int64 `protobuf:"varint,1,opt,name=add_start_time_ns,json=addStartTimeNs,proto3" json:"add_start_time_ns,omitempty"`
	// The exclusive end time for the query, used to filter HTLCs by the time they were added to
	// the local incoming channel. If this value is zero, it will be assumed to be the current time.
	AddEndTimeNs int64 `protobuf:"varint,2,opt,name=add_end_time_ns,json=addEndTimeNs,proto3" json:"add_end_time_ns,omitempty"`
	// contains filtered or unexported fields
}

func (*ListForwardingHistoryRequest) Descriptor deprecated

func (*ListForwardingHistoryRequest) Descriptor() ([]byte, []int)

Deprecated: Use ListForwardingHistoryRequest.ProtoReflect.Descriptor instead.

func (*ListForwardingHistoryRequest) GetAddEndTimeNs

func (x *ListForwardingHistoryRequest) GetAddEndTimeNs() int64

func (*ListForwardingHistoryRequest) GetAddStartTimeNs

func (x *ListForwardingHistoryRequest) GetAddStartTimeNs() int64

func (*ListForwardingHistoryRequest) ProtoMessage

func (*ListForwardingHistoryRequest) ProtoMessage()

func (*ListForwardingHistoryRequest) ProtoReflect

func (*ListForwardingHistoryRequest) Reset

func (x *ListForwardingHistoryRequest) Reset()

func (*ListForwardingHistoryRequest) String

func (*ListForwardingHistoryRequest) Validate

func (m *ListForwardingHistoryRequest) Validate() error

Validate checks the field values on ListForwardingHistoryRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type ListForwardingHistoryRequestValidationError

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

ListForwardingHistoryRequestValidationError is the validation error returned by ListForwardingHistoryRequest.Validate if the designated constraints aren't met.

func (ListForwardingHistoryRequestValidationError) Cause

Cause function returns cause value.

func (ListForwardingHistoryRequestValidationError) Error

Error satisfies the builtin error interface

func (ListForwardingHistoryRequestValidationError) ErrorName

ErrorName returns error name.

func (ListForwardingHistoryRequestValidationError) Field

Field function returns field value.

func (ListForwardingHistoryRequestValidationError) Key

Key function returns key value.

func (ListForwardingHistoryRequestValidationError) Reason

Reason function returns reason value.

type ListForwardingHistoryResponse

type ListForwardingHistoryResponse struct {
	Forwards []*Forward `protobuf:"bytes,1,rep,name=forwards,proto3" json:"forwards,omitempty"`
	// contains filtered or unexported fields
}

func (*ListForwardingHistoryResponse) Descriptor deprecated

func (*ListForwardingHistoryResponse) Descriptor() ([]byte, []int)

Deprecated: Use ListForwardingHistoryResponse.ProtoReflect.Descriptor instead.

func (*ListForwardingHistoryResponse) GetForwards

func (x *ListForwardingHistoryResponse) GetForwards() []*Forward

func (*ListForwardingHistoryResponse) ProtoMessage

func (*ListForwardingHistoryResponse) ProtoMessage()

func (*ListForwardingHistoryResponse) ProtoReflect

func (*ListForwardingHistoryResponse) Reset

func (x *ListForwardingHistoryResponse) Reset()

func (*ListForwardingHistoryResponse) String

func (*ListForwardingHistoryResponse) Validate

func (m *ListForwardingHistoryResponse) Validate() error

Validate checks the field values on ListForwardingHistoryResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type ListForwardingHistoryResponseValidationError

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

ListForwardingHistoryResponseValidationError is the validation error returned by ListForwardingHistoryResponse.Validate if the designated constraints aren't met.

func (ListForwardingHistoryResponseValidationError) Cause

Cause function returns cause value.

func (ListForwardingHistoryResponseValidationError) Error

Error satisfies the builtin error interface

func (ListForwardingHistoryResponseValidationError) ErrorName

ErrorName returns error name.

func (ListForwardingHistoryResponseValidationError) Field

Field function returns field value.

func (ListForwardingHistoryResponseValidationError) Key

Key function returns key value.

func (ListForwardingHistoryResponseValidationError) Reason

Reason function returns reason value.

type ListLimitsRequest

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

func (*ListLimitsRequest) Descriptor deprecated

func (*ListLimitsRequest) Descriptor() ([]byte, []int)

Deprecated: Use ListLimitsRequest.ProtoReflect.Descriptor instead.

func (*ListLimitsRequest) ProtoMessage

func (*ListLimitsRequest) ProtoMessage()

func (*ListLimitsRequest) ProtoReflect

func (x *ListLimitsRequest) ProtoReflect() protoreflect.Message

func (*ListLimitsRequest) Reset

func (x *ListLimitsRequest) Reset()

func (*ListLimitsRequest) String

func (x *ListLimitsRequest) String() string

func (*ListLimitsRequest) Validate

func (m *ListLimitsRequest) Validate() error

Validate checks the field values on ListLimitsRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type ListLimitsRequestValidationError

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

ListLimitsRequestValidationError is the validation error returned by ListLimitsRequest.Validate if the designated constraints aren't met.

func (ListLimitsRequestValidationError) Cause

Cause function returns cause value.

func (ListLimitsRequestValidationError) Error

Error satisfies the builtin error interface

func (ListLimitsRequestValidationError) ErrorName

ErrorName returns error name.

func (ListLimitsRequestValidationError) Field

Field function returns field value.

func (ListLimitsRequestValidationError) Key

Key function returns key value.

func (ListLimitsRequestValidationError) Reason

Reason function returns reason value.

type ListLimitsResponse

type ListLimitsResponse struct {
	Limits       []*NodeLimit `protobuf:"bytes,5,rep,name=limits,proto3" json:"limits,omitempty"`
	DefaultLimit *Limit       `protobuf:"bytes,2,opt,name=default_limit,json=defaultLimit,proto3" json:"default_limit,omitempty"`
	// contains filtered or unexported fields
}

func (*ListLimitsResponse) Descriptor deprecated

func (*ListLimitsResponse) Descriptor() ([]byte, []int)

Deprecated: Use ListLimitsResponse.ProtoReflect.Descriptor instead.

func (*ListLimitsResponse) GetDefaultLimit

func (x *ListLimitsResponse) GetDefaultLimit() *Limit

func (*ListLimitsResponse) GetLimits

func (x *ListLimitsResponse) GetLimits() []*NodeLimit

func (*ListLimitsResponse) ProtoMessage

func (*ListLimitsResponse) ProtoMessage()

func (*ListLimitsResponse) ProtoReflect

func (x *ListLimitsResponse) ProtoReflect() protoreflect.Message

func (*ListLimitsResponse) Reset

func (x *ListLimitsResponse) Reset()

func (*ListLimitsResponse) String

func (x *ListLimitsResponse) String() string

func (*ListLimitsResponse) Validate

func (m *ListLimitsResponse) Validate() error

Validate checks the field values on ListLimitsResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type ListLimitsResponseValidationError

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

ListLimitsResponseValidationError is the validation error returned by ListLimitsResponse.Validate if the designated constraints aren't met.

func (ListLimitsResponseValidationError) Cause

Cause function returns cause value.

func (ListLimitsResponseValidationError) Error

Error satisfies the builtin error interface

func (ListLimitsResponseValidationError) ErrorName

ErrorName returns error name.

func (ListLimitsResponseValidationError) Field

Field function returns field value.

func (ListLimitsResponseValidationError) Key

Key function returns key value.

func (ListLimitsResponseValidationError) Reason

Reason function returns reason value.

type Mode

type Mode int32
const (
	Mode_MODE_FAIL                 Mode = 0
	Mode_MODE_QUEUE                Mode = 1
	Mode_MODE_QUEUE_PEER_INITIATED Mode = 2
	Mode_MODE_BLOCK                Mode = 3
)

func (Mode) Descriptor

func (Mode) Descriptor() protoreflect.EnumDescriptor

func (Mode) Enum

func (x Mode) Enum() *Mode

func (Mode) EnumDescriptor deprecated

func (Mode) EnumDescriptor() ([]byte, []int)

Deprecated: Use Mode.Descriptor instead.

func (Mode) Number

func (x Mode) Number() protoreflect.EnumNumber

func (Mode) String

func (x Mode) String() string

func (Mode) Type

func (Mode) Type() protoreflect.EnumType

type NodeLimit

type NodeLimit struct {
	Node  string `protobuf:"bytes,1,opt,name=node,proto3" json:"node,omitempty"`
	Alias string `protobuf:"bytes,5,opt,name=alias,proto3" json:"alias,omitempty"`
	// The default limit applies if limit is not set.
	Limit            *Limit   `protobuf:"bytes,2,opt,name=limit,proto3" json:"limit,omitempty"`
	Counter_1H       *Counter `protobuf:"bytes,3,opt,name=counter_1h,json=counter1h,proto3" json:"counter_1h,omitempty"`
	Counter_24H      *Counter `protobuf:"bytes,4,opt,name=counter_24h,json=counter24h,proto3" json:"counter_24h,omitempty"`
	QueueLen         int64    `protobuf:"varint,6,opt,name=queue_len,json=queueLen,proto3" json:"queue_len,omitempty"`
	PendingHtlcCount int64    `protobuf:"varint,7,opt,name=pending_htlc_count,json=pendingHtlcCount,proto3" json:"pending_htlc_count,omitempty"`
	// contains filtered or unexported fields
}

func (*NodeLimit) Descriptor deprecated

func (*NodeLimit) Descriptor() ([]byte, []int)

Deprecated: Use NodeLimit.ProtoReflect.Descriptor instead.

func (*NodeLimit) GetAlias

func (x *NodeLimit) GetAlias() string

func (*NodeLimit) GetCounter_1H

func (x *NodeLimit) GetCounter_1H() *Counter

func (*NodeLimit) GetCounter_24H

func (x *NodeLimit) GetCounter_24H() *Counter

func (*NodeLimit) GetLimit

func (x *NodeLimit) GetLimit() *Limit

func (*NodeLimit) GetNode

func (x *NodeLimit) GetNode() string

func (*NodeLimit) GetPendingHtlcCount

func (x *NodeLimit) GetPendingHtlcCount() int64

func (*NodeLimit) GetQueueLen

func (x *NodeLimit) GetQueueLen() int64

func (*NodeLimit) ProtoMessage

func (*NodeLimit) ProtoMessage()

func (*NodeLimit) ProtoReflect

func (x *NodeLimit) ProtoReflect() protoreflect.Message

func (*NodeLimit) Reset

func (x *NodeLimit) Reset()

func (*NodeLimit) String

func (x *NodeLimit) String() string

func (*NodeLimit) Validate

func (m *NodeLimit) Validate() error

Validate checks the field values on NodeLimit with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type NodeLimitValidationError

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

NodeLimitValidationError is the validation error returned by NodeLimit.Validate if the designated constraints aren't met.

func (NodeLimitValidationError) Cause

func (e NodeLimitValidationError) Cause() error

Cause function returns cause value.

func (NodeLimitValidationError) Error

func (e NodeLimitValidationError) Error() string

Error satisfies the builtin error interface

func (NodeLimitValidationError) ErrorName

func (e NodeLimitValidationError) ErrorName() string

ErrorName returns error name.

func (NodeLimitValidationError) Field

func (e NodeLimitValidationError) Field() string

Field function returns field value.

func (NodeLimitValidationError) Key

Key function returns key value.

func (NodeLimitValidationError) Reason

func (e NodeLimitValidationError) Reason() string

Reason function returns reason value.

type ServiceClient

type ServiceClient interface {
	GetInfo(ctx context.Context, in *GetInfoRequest, opts ...grpc.CallOption) (*GetInfoResponse, error)
	UpdateLimits(ctx context.Context, in *UpdateLimitsRequest, opts ...grpc.CallOption) (*UpdateLimitsResponse, error)
	// Clear specific limits and use default.
	ClearLimits(ctx context.Context, in *ClearLimitsRequest, opts ...grpc.CallOption) (*ClearLimitsResponse, error)
	UpdateDefaultLimit(ctx context.Context, in *UpdateDefaultLimitRequest, opts ...grpc.CallOption) (*UpdateDefaultLimitResponse, error)
	ListLimits(ctx context.Context, in *ListLimitsRequest, opts ...grpc.CallOption) (*ListLimitsResponse, error)
	ListForwardingHistory(ctx context.Context, in *ListForwardingHistoryRequest, opts ...grpc.CallOption) (*ListForwardingHistoryResponse, error)
}

ServiceClient is the client API for Service service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewServiceClient

func NewServiceClient(cc grpc.ClientConnInterface) ServiceClient

type ServiceServer

type ServiceServer interface {
	GetInfo(context.Context, *GetInfoRequest) (*GetInfoResponse, error)
	UpdateLimits(context.Context, *UpdateLimitsRequest) (*UpdateLimitsResponse, error)
	// Clear specific limits and use default.
	ClearLimits(context.Context, *ClearLimitsRequest) (*ClearLimitsResponse, error)
	UpdateDefaultLimit(context.Context, *UpdateDefaultLimitRequest) (*UpdateDefaultLimitResponse, error)
	ListLimits(context.Context, *ListLimitsRequest) (*ListLimitsResponse, error)
	ListForwardingHistory(context.Context, *ListForwardingHistoryRequest) (*ListForwardingHistoryResponse, error)
	// contains filtered or unexported methods
}

ServiceServer is the server API for Service service. All implementations must embed UnimplementedServiceServer for forward compatibility

type UnimplementedServiceServer

type UnimplementedServiceServer struct {
}

UnimplementedServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedServiceServer) ClearLimits

func (UnimplementedServiceServer) GetInfo

func (UnimplementedServiceServer) ListLimits

func (UnimplementedServiceServer) UpdateLimits

type UnsafeServiceServer

type UnsafeServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ServiceServer will result in compilation errors.

type UpdateDefaultLimitRequest

type UpdateDefaultLimitRequest struct {
	Limit *Limit `protobuf:"bytes,1,opt,name=limit,proto3" json:"limit,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateDefaultLimitRequest) Descriptor deprecated

func (*UpdateDefaultLimitRequest) Descriptor() ([]byte, []int)

Deprecated: Use UpdateDefaultLimitRequest.ProtoReflect.Descriptor instead.

func (*UpdateDefaultLimitRequest) GetLimit

func (x *UpdateDefaultLimitRequest) GetLimit() *Limit

func (*UpdateDefaultLimitRequest) ProtoMessage

func (*UpdateDefaultLimitRequest) ProtoMessage()

func (*UpdateDefaultLimitRequest) ProtoReflect

func (*UpdateDefaultLimitRequest) Reset

func (x *UpdateDefaultLimitRequest) Reset()

func (*UpdateDefaultLimitRequest) String

func (x *UpdateDefaultLimitRequest) String() string

func (*UpdateDefaultLimitRequest) Validate

func (m *UpdateDefaultLimitRequest) Validate() error

Validate checks the field values on UpdateDefaultLimitRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type UpdateDefaultLimitRequestValidationError

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

UpdateDefaultLimitRequestValidationError is the validation error returned by UpdateDefaultLimitRequest.Validate if the designated constraints aren't met.

func (UpdateDefaultLimitRequestValidationError) Cause

Cause function returns cause value.

func (UpdateDefaultLimitRequestValidationError) Error

Error satisfies the builtin error interface

func (UpdateDefaultLimitRequestValidationError) ErrorName

ErrorName returns error name.

func (UpdateDefaultLimitRequestValidationError) Field

Field function returns field value.

func (UpdateDefaultLimitRequestValidationError) Key

Key function returns key value.

func (UpdateDefaultLimitRequestValidationError) Reason

Reason function returns reason value.

type UpdateDefaultLimitResponse

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

func (*UpdateDefaultLimitResponse) Descriptor deprecated

func (*UpdateDefaultLimitResponse) Descriptor() ([]byte, []int)

Deprecated: Use UpdateDefaultLimitResponse.ProtoReflect.Descriptor instead.

func (*UpdateDefaultLimitResponse) ProtoMessage

func (*UpdateDefaultLimitResponse) ProtoMessage()

func (*UpdateDefaultLimitResponse) ProtoReflect

func (*UpdateDefaultLimitResponse) Reset

func (x *UpdateDefaultLimitResponse) Reset()

func (*UpdateDefaultLimitResponse) String

func (x *UpdateDefaultLimitResponse) String() string

func (*UpdateDefaultLimitResponse) Validate

func (m *UpdateDefaultLimitResponse) Validate() error

Validate checks the field values on UpdateDefaultLimitResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type UpdateDefaultLimitResponseValidationError

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

UpdateDefaultLimitResponseValidationError is the validation error returned by UpdateDefaultLimitResponse.Validate if the designated constraints aren't met.

func (UpdateDefaultLimitResponseValidationError) Cause

Cause function returns cause value.

func (UpdateDefaultLimitResponseValidationError) Error

Error satisfies the builtin error interface

func (UpdateDefaultLimitResponseValidationError) ErrorName

ErrorName returns error name.

func (UpdateDefaultLimitResponseValidationError) Field

Field function returns field value.

func (UpdateDefaultLimitResponseValidationError) Key

Key function returns key value.

func (UpdateDefaultLimitResponseValidationError) Reason

Reason function returns reason value.

type UpdateLimitsRequest

type UpdateLimitsRequest struct {
	Limits map[string]*Limit `` /* 153-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*UpdateLimitsRequest) Descriptor deprecated

func (*UpdateLimitsRequest) Descriptor() ([]byte, []int)

Deprecated: Use UpdateLimitsRequest.ProtoReflect.Descriptor instead.

func (*UpdateLimitsRequest) GetLimits

func (x *UpdateLimitsRequest) GetLimits() map[string]*Limit

func (*UpdateLimitsRequest) ProtoMessage

func (*UpdateLimitsRequest) ProtoMessage()

func (*UpdateLimitsRequest) ProtoReflect

func (x *UpdateLimitsRequest) ProtoReflect() protoreflect.Message

func (*UpdateLimitsRequest) Reset

func (x *UpdateLimitsRequest) Reset()

func (*UpdateLimitsRequest) String

func (x *UpdateLimitsRequest) String() string

func (*UpdateLimitsRequest) Validate

func (m *UpdateLimitsRequest) Validate() error

Validate checks the field values on UpdateLimitsRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type UpdateLimitsRequestValidationError

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

UpdateLimitsRequestValidationError is the validation error returned by UpdateLimitsRequest.Validate if the designated constraints aren't met.

func (UpdateLimitsRequestValidationError) Cause

Cause function returns cause value.

func (UpdateLimitsRequestValidationError) Error

Error satisfies the builtin error interface

func (UpdateLimitsRequestValidationError) ErrorName

ErrorName returns error name.

func (UpdateLimitsRequestValidationError) Field

Field function returns field value.

func (UpdateLimitsRequestValidationError) Key

Key function returns key value.

func (UpdateLimitsRequestValidationError) Reason

Reason function returns reason value.

type UpdateLimitsResponse

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

func (*UpdateLimitsResponse) Descriptor deprecated

func (*UpdateLimitsResponse) Descriptor() ([]byte, []int)

Deprecated: Use UpdateLimitsResponse.ProtoReflect.Descriptor instead.

func (*UpdateLimitsResponse) ProtoMessage

func (*UpdateLimitsResponse) ProtoMessage()

func (*UpdateLimitsResponse) ProtoReflect

func (x *UpdateLimitsResponse) ProtoReflect() protoreflect.Message

func (*UpdateLimitsResponse) Reset

func (x *UpdateLimitsResponse) Reset()

func (*UpdateLimitsResponse) String

func (x *UpdateLimitsResponse) String() string

func (*UpdateLimitsResponse) Validate

func (m *UpdateLimitsResponse) Validate() error

Validate checks the field values on UpdateLimitsResponse with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type UpdateLimitsResponseValidationError

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

UpdateLimitsResponseValidationError is the validation error returned by UpdateLimitsResponse.Validate if the designated constraints aren't met.

func (UpdateLimitsResponseValidationError) Cause

Cause function returns cause value.

func (UpdateLimitsResponseValidationError) Error

Error satisfies the builtin error interface

func (UpdateLimitsResponseValidationError) ErrorName

ErrorName returns error name.

func (UpdateLimitsResponseValidationError) Field

Field function returns field value.

func (UpdateLimitsResponseValidationError) Key

Key function returns key value.

func (UpdateLimitsResponseValidationError) Reason

Reason function returns reason value.

Jump to

Keyboard shortcuts

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