Documentation ¶
Index ¶
- Variables
- type GetTunnelsByAgentIdCallback
- type Querier
- type RedisTracker
- func (t *RedisTracker) GetTunnelsByAgentId(ctx context.Context, agentId int64, cb GetTunnelsByAgentIdCallback) error
- func (t *RedisTracker) RegisterTunnel(ctx context.Context, info *TunnelInfo) bool
- func (t *RedisTracker) Run(ctx context.Context) error
- func (t *RedisTracker) UnregisterTunnel(ctx context.Context, info *TunnelInfo) bool
- type Registerer
- type Tracker
- type TunnelInfo
- func (*TunnelInfo) Descriptor() ([]byte, []int)deprecated
- func (x *TunnelInfo) GetAgentDescriptor() *info.AgentDescriptor
- func (x *TunnelInfo) GetAgentId() int64
- func (x *TunnelInfo) GetConnectionId() int64
- func (x *TunnelInfo) GetKasUrl() string
- func (*TunnelInfo) ProtoMessage()
- func (x *TunnelInfo) ProtoReflect() protoreflect.Message
- func (x *TunnelInfo) Reset()
- func (x *TunnelInfo) String() string
- func (x *TunnelInfo) SupportsServiceAndMethod(service, method string) bool
- func (m *TunnelInfo) Validate() error
- func (m *TunnelInfo) ValidateAll() error
- type TunnelInfoCollector
- type TunnelInfoMultiError
- type TunnelInfoValidationError
Constants ¶
This section is empty.
Variables ¶
var File_internal_module_reverse_tunnel_tracker_tracker_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type GetTunnelsByAgentIdCallback ¶
type GetTunnelsByAgentIdCallback func(*TunnelInfo) (bool, error)
type Querier ¶
type Querier interface {
GetTunnelsByAgentId(ctx context.Context, agentId int64, cb GetTunnelsByAgentIdCallback) error
}
type RedisTracker ¶
type RedisTracker struct {
// contains filtered or unexported fields
}
func NewRedisTracker ¶
func (*RedisTracker) GetTunnelsByAgentId ¶
func (t *RedisTracker) GetTunnelsByAgentId(ctx context.Context, agentId int64, cb GetTunnelsByAgentIdCallback) error
func (*RedisTracker) RegisterTunnel ¶
func (t *RedisTracker) RegisterTunnel(ctx context.Context, info *TunnelInfo) bool
func (*RedisTracker) UnregisterTunnel ¶
func (t *RedisTracker) UnregisterTunnel(ctx context.Context, info *TunnelInfo) bool
type Registerer ¶
type Registerer interface { // RegisterTunnel schedules the tunnel to be registered with the tracker. // Returns true on success and false if ctx signaled done. RegisterTunnel(ctx context.Context, info *TunnelInfo) bool // UnregisterTunnel schedules the tunnel to be unregistered with the tracker. // Returns true on success and false if ctx signaled done. UnregisterTunnel(ctx context.Context, info *TunnelInfo) bool }
type TunnelInfo ¶
type TunnelInfo struct { AgentDescriptor *info.AgentDescriptor `protobuf:"bytes,1,opt,name=agent_descriptor,json=agentDescriptor,proto3" json:"agent_descriptor,omitempty"` ConnectionId int64 `protobuf:"varint,2,opt,name=connection_id,json=connectionId,proto3" json:"connection_id,omitempty"` AgentId int64 `protobuf:"varint,3,opt,name=agent_id,json=agentId,proto3" json:"agent_id,omitempty"` KasUrl string `protobuf:"bytes,4,opt,name=kas_url,json=kasUrl,proto3" json:"kas_url,omitempty"` // contains filtered or unexported fields }
func (*TunnelInfo) Descriptor
deprecated
func (*TunnelInfo) Descriptor() ([]byte, []int)
Deprecated: Use TunnelInfo.ProtoReflect.Descriptor instead.
func (*TunnelInfo) GetAgentDescriptor ¶
func (x *TunnelInfo) GetAgentDescriptor() *info.AgentDescriptor
func (*TunnelInfo) GetAgentId ¶
func (x *TunnelInfo) GetAgentId() int64
func (*TunnelInfo) GetConnectionId ¶
func (x *TunnelInfo) GetConnectionId() int64
func (*TunnelInfo) GetKasUrl ¶
func (x *TunnelInfo) GetKasUrl() string
func (*TunnelInfo) ProtoMessage ¶
func (*TunnelInfo) ProtoMessage()
func (*TunnelInfo) ProtoReflect ¶
func (x *TunnelInfo) ProtoReflect() protoreflect.Message
func (*TunnelInfo) Reset ¶
func (x *TunnelInfo) Reset()
func (*TunnelInfo) String ¶
func (x *TunnelInfo) String() string
func (*TunnelInfo) SupportsServiceAndMethod ¶ added in v14.3.0
func (x *TunnelInfo) SupportsServiceAndMethod(service, method string) bool
func (*TunnelInfo) Validate ¶
func (m *TunnelInfo) Validate() error
Validate checks the field values on TunnelInfo with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*TunnelInfo) ValidateAll ¶ added in v14.5.0
func (m *TunnelInfo) ValidateAll() error
ValidateAll checks the field values on TunnelInfo with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in TunnelInfoMultiError, or nil if none found.
type TunnelInfoCollector ¶
type TunnelInfoCollector []*TunnelInfo
func (*TunnelInfoCollector) Collect ¶
func (c *TunnelInfoCollector) Collect(info *TunnelInfo) (bool, error)
type TunnelInfoMultiError ¶ added in v14.5.0
type TunnelInfoMultiError []error
TunnelInfoMultiError is an error wrapping multiple validation errors returned by TunnelInfo.ValidateAll() if the designated constraints aren't met.
func (TunnelInfoMultiError) AllErrors ¶ added in v14.5.0
func (m TunnelInfoMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (TunnelInfoMultiError) Error ¶ added in v14.5.0
func (m TunnelInfoMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type TunnelInfoValidationError ¶
type TunnelInfoValidationError struct {
// contains filtered or unexported fields
}
TunnelInfoValidationError is the validation error returned by TunnelInfo.Validate if the designated constraints aren't met.
func (TunnelInfoValidationError) Cause ¶
func (e TunnelInfoValidationError) Cause() error
Cause function returns cause value.
func (TunnelInfoValidationError) Error ¶
func (e TunnelInfoValidationError) Error() string
Error satisfies the builtin error interface
func (TunnelInfoValidationError) ErrorName ¶
func (e TunnelInfoValidationError) ErrorName() string
ErrorName returns error name.
func (TunnelInfoValidationError) Field ¶
func (e TunnelInfoValidationError) Field() string
Field function returns field value.
func (TunnelInfoValidationError) Key ¶
func (e TunnelInfoValidationError) Key() bool
Key function returns key value.
func (TunnelInfoValidationError) Reason ¶
func (e TunnelInfoValidationError) Reason() string
Reason function returns reason value.