Documentation ¶
Index ¶
- Variables
- func CheckServiceNodeToStructs(s *CheckServiceNode) *structs.CheckServiceNode
- func CheckTypeToStructs(s CheckType) structs.CheckType
- func CheckTypesToStructs(s []*CheckType) structs.CheckTypes
- func ConnectProxyConfigPtrToStructs(s *ConnectProxyConfig) *structs.ConnectProxyConfig
- func ConnectProxyConfigToStructs(s ConnectProxyConfig) structs.ConnectProxyConfig
- func EnterpriseMetaToStructs(_ pbcommon.EnterpriseMeta) structs.EnterpriseMeta
- func ExposeConfigToStructs(s ExposeConfig) structs.ExposeConfig
- func ExposePathSliceToStructs(s []ExposePath) []structs.ExposePath
- func ExposePathToStructs(s ExposePath) structs.ExposePath
- func HealthCheckDefinitionToStructs(s HealthCheckDefinition) structs.HealthCheckDefinition
- func HealthCheckToStructs(s HealthCheck) structs.HealthCheck
- func MapHeadersToStructs(s map[string]HeaderValue) map[string][]string
- func MapStringInterfaceToProtobufTypesStruct(m map[string]interface{}) *types.Struct
- func MapStringServiceAddressToStructs(s map[string]ServiceAddress) map[string]structs.ServiceAddress
- func MeshGatewayConfigToStructs(s MeshGatewayConfig) structs.MeshGatewayConfig
- func NewEnterpriseMetaFromStructs(_ structs.EnterpriseMeta) pbcommon.EnterpriseMeta
- func NewMapHeadersFromStructs(t map[string][]string) map[string]HeaderValue
- func NewMapStringServiceAddressFromStructs(t map[string]structs.ServiceAddress) map[string]ServiceAddress
- func NewRaftIndexFromStructs(s structs.RaftIndex) pbcommon.RaftIndex
- func NodeServiceToStructs(s NodeService) structs.NodeService
- func NodeToStructs(s Node) structs.Node
- func ProtobufTypesStructToMapStringInterface(s *types.Struct) map[string]interface{}
- func RaftIndexToStructs(s pbcommon.RaftIndex) structs.RaftIndex
- func ServiceConnectPtrToStructs(s *ServiceConnect) *structs.ServiceConnect
- func ServiceConnectToStructs(s ServiceConnect) structs.ServiceConnect
- func ServiceDefinitionPtrToStructs(s *ServiceDefinition) *structs.ServiceDefinition
- func ServiceDefinitionToStructs(s ServiceDefinition) structs.ServiceDefinition
- func SliceToPBListValue(s []interface{}) *types.ListValue
- func UpstreamToStructs(s Upstream) structs.Upstream
- func UpstreamsToStructs(s []Upstream) structs.Upstreams
- func WeightsPtrToStructs(s *Weights) *structs.Weights
- type CheckServiceNode
- func (*CheckServiceNode) Descriptor() ([]byte, []int)
- func (m *CheckServiceNode) Marshal() (dAtA []byte, err error)
- func (msg *CheckServiceNode) MarshalBinary() ([]byte, error)
- func (m *CheckServiceNode) MarshalTo(dAtA []byte) (int, error)
- func (m *CheckServiceNode) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*CheckServiceNode) ProtoMessage()
- func (m *CheckServiceNode) Reset()
- func (m *CheckServiceNode) Size() (n int)
- func (m *CheckServiceNode) String() string
- func (m *CheckServiceNode) UniqueID() string
- func (m *CheckServiceNode) Unmarshal(dAtA []byte) error
- func (msg *CheckServiceNode) UnmarshalBinary(b []byte) error
- func (m *CheckServiceNode) XXX_DiscardUnknown()
- func (m *CheckServiceNode) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *CheckServiceNode) XXX_Merge(src proto.Message)
- func (m *CheckServiceNode) XXX_Size() int
- func (m *CheckServiceNode) XXX_Unmarshal(b []byte) error
- type CheckType
- func (*CheckType) Descriptor() ([]byte, []int)
- func (m *CheckType) Marshal() (dAtA []byte, err error)
- func (msg *CheckType) MarshalBinary() ([]byte, error)
- func (m *CheckType) MarshalTo(dAtA []byte) (int, error)
- func (m *CheckType) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*CheckType) ProtoMessage()
- func (m *CheckType) Reset()
- func (m *CheckType) Size() (n int)
- func (m *CheckType) String() string
- func (m *CheckType) Unmarshal(dAtA []byte) error
- func (msg *CheckType) UnmarshalBinary(b []byte) error
- func (m *CheckType) XXX_DiscardUnknown()
- func (m *CheckType) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *CheckType) XXX_Merge(src proto.Message)
- func (m *CheckType) XXX_Size() int
- func (m *CheckType) XXX_Unmarshal(b []byte) error
- type ConnectProxyConfig
- func (*ConnectProxyConfig) Descriptor() ([]byte, []int)
- func (m *ConnectProxyConfig) Marshal() (dAtA []byte, err error)
- func (msg *ConnectProxyConfig) MarshalBinary() ([]byte, error)
- func (m *ConnectProxyConfig) MarshalTo(dAtA []byte) (int, error)
- func (m *ConnectProxyConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ConnectProxyConfig) ProtoMessage()
- func (m *ConnectProxyConfig) Reset()
- func (m *ConnectProxyConfig) Size() (n int)
- func (m *ConnectProxyConfig) String() string
- func (m *ConnectProxyConfig) Unmarshal(dAtA []byte) error
- func (msg *ConnectProxyConfig) UnmarshalBinary(b []byte) error
- func (m *ConnectProxyConfig) XXX_DiscardUnknown()
- func (m *ConnectProxyConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ConnectProxyConfig) XXX_Merge(src proto.Message)
- func (m *ConnectProxyConfig) XXX_Size() int
- func (m *ConnectProxyConfig) XXX_Unmarshal(b []byte) error
- type ExposeConfig
- func (*ExposeConfig) Descriptor() ([]byte, []int)
- func (m *ExposeConfig) Marshal() (dAtA []byte, err error)
- func (msg *ExposeConfig) MarshalBinary() ([]byte, error)
- func (m *ExposeConfig) MarshalTo(dAtA []byte) (int, error)
- func (m *ExposeConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ExposeConfig) ProtoMessage()
- func (m *ExposeConfig) Reset()
- func (m *ExposeConfig) Size() (n int)
- func (m *ExposeConfig) String() string
- func (m *ExposeConfig) Unmarshal(dAtA []byte) error
- func (msg *ExposeConfig) UnmarshalBinary(b []byte) error
- func (m *ExposeConfig) XXX_DiscardUnknown()
- func (m *ExposeConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ExposeConfig) XXX_Merge(src proto.Message)
- func (m *ExposeConfig) XXX_Size() int
- func (m *ExposeConfig) XXX_Unmarshal(b []byte) error
- type ExposePath
- func (*ExposePath) Descriptor() ([]byte, []int)
- func (m *ExposePath) Marshal() (dAtA []byte, err error)
- func (msg *ExposePath) MarshalBinary() ([]byte, error)
- func (m *ExposePath) MarshalTo(dAtA []byte) (int, error)
- func (m *ExposePath) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ExposePath) ProtoMessage()
- func (m *ExposePath) Reset()
- func (m *ExposePath) Size() (n int)
- func (m *ExposePath) String() string
- func (m *ExposePath) Unmarshal(dAtA []byte) error
- func (msg *ExposePath) UnmarshalBinary(b []byte) error
- func (m *ExposePath) XXX_DiscardUnknown()
- func (m *ExposePath) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ExposePath) XXX_Merge(src proto.Message)
- func (m *ExposePath) XXX_Size() int
- func (m *ExposePath) XXX_Unmarshal(b []byte) error
- type HeaderValue
- func (*HeaderValue) Descriptor() ([]byte, []int)
- func (m *HeaderValue) Marshal() (dAtA []byte, err error)
- func (msg *HeaderValue) MarshalBinary() ([]byte, error)
- func (m *HeaderValue) MarshalTo(dAtA []byte) (int, error)
- func (m *HeaderValue) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*HeaderValue) ProtoMessage()
- func (m *HeaderValue) Reset()
- func (m *HeaderValue) Size() (n int)
- func (m *HeaderValue) String() string
- func (m *HeaderValue) Unmarshal(dAtA []byte) error
- func (msg *HeaderValue) UnmarshalBinary(b []byte) error
- func (m *HeaderValue) XXX_DiscardUnknown()
- func (m *HeaderValue) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *HeaderValue) XXX_Merge(src proto.Message)
- func (m *HeaderValue) XXX_Size() int
- func (m *HeaderValue) XXX_Unmarshal(b []byte) error
- type HealthCheck
- func (*HealthCheck) Descriptor() ([]byte, []int)
- func (m *HealthCheck) Marshal() (dAtA []byte, err error)
- func (msg *HealthCheck) MarshalBinary() ([]byte, error)
- func (m *HealthCheck) MarshalTo(dAtA []byte) (int, error)
- func (m *HealthCheck) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*HealthCheck) ProtoMessage()
- func (m *HealthCheck) Reset()
- func (m *HealthCheck) Size() (n int)
- func (m *HealthCheck) String() string
- func (m *HealthCheck) Unmarshal(dAtA []byte) error
- func (msg *HealthCheck) UnmarshalBinary(b []byte) error
- func (m *HealthCheck) XXX_DiscardUnknown()
- func (m *HealthCheck) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *HealthCheck) XXX_Merge(src proto.Message)
- func (m *HealthCheck) XXX_Size() int
- func (m *HealthCheck) XXX_Unmarshal(b []byte) error
- type HealthCheckDefinition
- func (*HealthCheckDefinition) Descriptor() ([]byte, []int)
- func (m *HealthCheckDefinition) Marshal() (dAtA []byte, err error)
- func (msg *HealthCheckDefinition) MarshalBinary() ([]byte, error)
- func (m *HealthCheckDefinition) MarshalTo(dAtA []byte) (int, error)
- func (m *HealthCheckDefinition) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*HealthCheckDefinition) ProtoMessage()
- func (m *HealthCheckDefinition) Reset()
- func (m *HealthCheckDefinition) Size() (n int)
- func (m *HealthCheckDefinition) String() string
- func (m *HealthCheckDefinition) Unmarshal(dAtA []byte) error
- func (msg *HealthCheckDefinition) UnmarshalBinary(b []byte) error
- func (m *HealthCheckDefinition) XXX_DiscardUnknown()
- func (m *HealthCheckDefinition) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *HealthCheckDefinition) XXX_Merge(src proto.Message)
- func (m *HealthCheckDefinition) XXX_Size() int
- func (m *HealthCheckDefinition) XXX_Unmarshal(b []byte) error
- type MeshGatewayConfig
- func (*MeshGatewayConfig) Descriptor() ([]byte, []int)
- func (m *MeshGatewayConfig) Marshal() (dAtA []byte, err error)
- func (msg *MeshGatewayConfig) MarshalBinary() ([]byte, error)
- func (m *MeshGatewayConfig) MarshalTo(dAtA []byte) (int, error)
- func (m *MeshGatewayConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MeshGatewayConfig) ProtoMessage()
- func (m *MeshGatewayConfig) Reset()
- func (m *MeshGatewayConfig) Size() (n int)
- func (m *MeshGatewayConfig) String() string
- func (m *MeshGatewayConfig) Unmarshal(dAtA []byte) error
- func (msg *MeshGatewayConfig) UnmarshalBinary(b []byte) error
- func (m *MeshGatewayConfig) XXX_DiscardUnknown()
- func (m *MeshGatewayConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MeshGatewayConfig) XXX_Merge(src proto.Message)
- func (m *MeshGatewayConfig) XXX_Size() int
- func (m *MeshGatewayConfig) XXX_Unmarshal(b []byte) error
- type Node
- func (*Node) Descriptor() ([]byte, []int)
- func (m *Node) Marshal() (dAtA []byte, err error)
- func (msg *Node) MarshalBinary() ([]byte, error)
- func (m *Node) MarshalTo(dAtA []byte) (int, error)
- func (m *Node) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Node) ProtoMessage()
- func (m *Node) Reset()
- func (m *Node) Size() (n int)
- func (m *Node) String() string
- func (m *Node) Unmarshal(dAtA []byte) error
- func (msg *Node) UnmarshalBinary(b []byte) error
- func (m *Node) XXX_DiscardUnknown()
- func (m *Node) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Node) XXX_Merge(src proto.Message)
- func (m *Node) XXX_Size() int
- func (m *Node) XXX_Unmarshal(b []byte) error
- type NodeService
- func (*NodeService) Descriptor() ([]byte, []int)
- func (m *NodeService) Marshal() (dAtA []byte, err error)
- func (msg *NodeService) MarshalBinary() ([]byte, error)
- func (m *NodeService) MarshalTo(dAtA []byte) (int, error)
- func (m *NodeService) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*NodeService) ProtoMessage()
- func (m *NodeService) Reset()
- func (m *NodeService) Size() (n int)
- func (m *NodeService) String() string
- func (m *NodeService) Unmarshal(dAtA []byte) error
- func (msg *NodeService) UnmarshalBinary(b []byte) error
- func (m *NodeService) XXX_DiscardUnknown()
- func (m *NodeService) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *NodeService) XXX_Merge(src proto.Message)
- func (m *NodeService) XXX_Size() int
- func (m *NodeService) XXX_Unmarshal(b []byte) error
- type ServiceAddress
- func (*ServiceAddress) Descriptor() ([]byte, []int)
- func (m *ServiceAddress) Marshal() (dAtA []byte, err error)
- func (msg *ServiceAddress) MarshalBinary() ([]byte, error)
- func (m *ServiceAddress) MarshalTo(dAtA []byte) (int, error)
- func (m *ServiceAddress) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ServiceAddress) ProtoMessage()
- func (m *ServiceAddress) Reset()
- func (m *ServiceAddress) Size() (n int)
- func (m *ServiceAddress) String() string
- func (m *ServiceAddress) Unmarshal(dAtA []byte) error
- func (msg *ServiceAddress) UnmarshalBinary(b []byte) error
- func (m *ServiceAddress) XXX_DiscardUnknown()
- func (m *ServiceAddress) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ServiceAddress) XXX_Merge(src proto.Message)
- func (m *ServiceAddress) XXX_Size() int
- func (m *ServiceAddress) XXX_Unmarshal(b []byte) error
- type ServiceConnect
- func (*ServiceConnect) Descriptor() ([]byte, []int)
- func (m *ServiceConnect) Marshal() (dAtA []byte, err error)
- func (msg *ServiceConnect) MarshalBinary() ([]byte, error)
- func (m *ServiceConnect) MarshalTo(dAtA []byte) (int, error)
- func (m *ServiceConnect) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ServiceConnect) ProtoMessage()
- func (m *ServiceConnect) Reset()
- func (m *ServiceConnect) Size() (n int)
- func (m *ServiceConnect) String() string
- func (m *ServiceConnect) Unmarshal(dAtA []byte) error
- func (msg *ServiceConnect) UnmarshalBinary(b []byte) error
- func (m *ServiceConnect) XXX_DiscardUnknown()
- func (m *ServiceConnect) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ServiceConnect) XXX_Merge(src proto.Message)
- func (m *ServiceConnect) XXX_Size() int
- func (m *ServiceConnect) XXX_Unmarshal(b []byte) error
- type ServiceDefinition
- func (*ServiceDefinition) Descriptor() ([]byte, []int)
- func (m *ServiceDefinition) Marshal() (dAtA []byte, err error)
- func (msg *ServiceDefinition) MarshalBinary() ([]byte, error)
- func (m *ServiceDefinition) MarshalTo(dAtA []byte) (int, error)
- func (m *ServiceDefinition) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ServiceDefinition) ProtoMessage()
- func (m *ServiceDefinition) Reset()
- func (m *ServiceDefinition) Size() (n int)
- func (m *ServiceDefinition) String() string
- func (m *ServiceDefinition) Unmarshal(dAtA []byte) error
- func (msg *ServiceDefinition) UnmarshalBinary(b []byte) error
- func (m *ServiceDefinition) XXX_DiscardUnknown()
- func (m *ServiceDefinition) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ServiceDefinition) XXX_Merge(src proto.Message)
- func (m *ServiceDefinition) XXX_Size() int
- func (m *ServiceDefinition) XXX_Unmarshal(b []byte) error
- type Upstream
- func (*Upstream) Descriptor() ([]byte, []int)
- func (m *Upstream) Marshal() (dAtA []byte, err error)
- func (msg *Upstream) MarshalBinary() ([]byte, error)
- func (m *Upstream) MarshalTo(dAtA []byte) (int, error)
- func (m *Upstream) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Upstream) ProtoMessage()
- func (m *Upstream) Reset()
- func (m *Upstream) Size() (n int)
- func (m *Upstream) String() string
- func (m *Upstream) Unmarshal(dAtA []byte) error
- func (msg *Upstream) UnmarshalBinary(b []byte) error
- func (m *Upstream) XXX_DiscardUnknown()
- func (m *Upstream) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Upstream) XXX_Merge(src proto.Message)
- func (m *Upstream) XXX_Size() int
- func (m *Upstream) XXX_Unmarshal(b []byte) error
- type Weights
- func (*Weights) Descriptor() ([]byte, []int)
- func (m *Weights) Marshal() (dAtA []byte, err error)
- func (msg *Weights) MarshalBinary() ([]byte, error)
- func (m *Weights) MarshalTo(dAtA []byte) (int, error)
- func (m *Weights) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Weights) ProtoMessage()
- func (m *Weights) Reset()
- func (m *Weights) Size() (n int)
- func (m *Weights) String() string
- func (m *Weights) Unmarshal(dAtA []byte) error
- func (msg *Weights) UnmarshalBinary(b []byte) error
- func (m *Weights) XXX_DiscardUnknown()
- func (m *Weights) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Weights) XXX_Merge(src proto.Message)
- func (m *Weights) XXX_Size() int
- func (m *Weights) XXX_Unmarshal(b []byte) error
Constants ¶
This section is empty.
Variables ¶
var ( ErrInvalidLengthHealthcheck = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowHealthcheck = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupHealthcheck = fmt.Errorf("proto: unexpected end of group") )
Functions ¶
func CheckServiceNodeToStructs ¶
func CheckServiceNodeToStructs(s *CheckServiceNode) *structs.CheckServiceNode
TODO: use mog once it supports pointers and slices
func CheckTypeToStructs ¶
func CheckTypesToStructs ¶
func CheckTypesToStructs(s []*CheckType) structs.CheckTypes
TODO: handle this with mog
func ConnectProxyConfigPtrToStructs ¶
func ConnectProxyConfigPtrToStructs(s *ConnectProxyConfig) *structs.ConnectProxyConfig
TODO: handle this with mog
func ConnectProxyConfigToStructs ¶
func ConnectProxyConfigToStructs(s ConnectProxyConfig) structs.ConnectProxyConfig
func EnterpriseMetaToStructs ¶
func EnterpriseMetaToStructs(_ pbcommon.EnterpriseMeta) structs.EnterpriseMeta
func ExposeConfigToStructs ¶
func ExposeConfigToStructs(s ExposeConfig) structs.ExposeConfig
func ExposePathSliceToStructs ¶
func ExposePathSliceToStructs(s []ExposePath) []structs.ExposePath
TODO: handle this with mog
func ExposePathToStructs ¶
func ExposePathToStructs(s ExposePath) structs.ExposePath
func HealthCheckDefinitionToStructs ¶
func HealthCheckDefinitionToStructs(s HealthCheckDefinition) structs.HealthCheckDefinition
func HealthCheckToStructs ¶
func HealthCheckToStructs(s HealthCheck) structs.HealthCheck
func MapHeadersToStructs ¶
func MapHeadersToStructs(s map[string]HeaderValue) map[string][]string
func MapStringInterfaceToProtobufTypesStruct ¶
MapStringInterfaceToProtobufTypesStruct converts a map[string]interface{} into a proto.Struct
func MapStringServiceAddressToStructs ¶
func MapStringServiceAddressToStructs(s map[string]ServiceAddress) map[string]structs.ServiceAddress
TODO: handle this with mog
func MeshGatewayConfigToStructs ¶
func MeshGatewayConfigToStructs(s MeshGatewayConfig) structs.MeshGatewayConfig
func NewEnterpriseMetaFromStructs ¶
func NewEnterpriseMetaFromStructs(_ structs.EnterpriseMeta) pbcommon.EnterpriseMeta
func NewMapHeadersFromStructs ¶
func NewMapHeadersFromStructs(t map[string][]string) map[string]HeaderValue
func NewMapStringServiceAddressFromStructs ¶
func NewMapStringServiceAddressFromStructs(t map[string]structs.ServiceAddress) map[string]ServiceAddress
TODO: handle this with mog
func NodeServiceToStructs ¶
func NodeServiceToStructs(s NodeService) structs.NodeService
func NodeToStructs ¶
func ProtobufTypesStructToMapStringInterface ¶
ProtobufTypesStructToMapStringInterface converts a protobuf/types.Struct into a map[string]interface{}.
func ServiceConnectPtrToStructs ¶
func ServiceConnectPtrToStructs(s *ServiceConnect) *structs.ServiceConnect
TODO: handle this with mog
func ServiceConnectToStructs ¶
func ServiceConnectToStructs(s ServiceConnect) structs.ServiceConnect
func ServiceDefinitionPtrToStructs ¶
func ServiceDefinitionPtrToStructs(s *ServiceDefinition) *structs.ServiceDefinition
TODO: handle this with mog
func ServiceDefinitionToStructs ¶
func ServiceDefinitionToStructs(s ServiceDefinition) structs.ServiceDefinition
func SliceToPBListValue ¶
SliceToPBListValue converts a []interface{} into a proto.ListValue. It's used internally by MapStringInterfaceToProtobufTypesStruct when it encouters slices.
func UpstreamToStructs ¶
func UpstreamsToStructs ¶
TODO: handle this with mog
func WeightsPtrToStructs ¶
TODO: handle this with mog, once mog handles pointers
Types ¶
type CheckServiceNode ¶
type CheckServiceNode struct { Node *Node `protobuf:"bytes,1,opt,name=Node,proto3" json:"Node,omitempty"` Service *NodeService `protobuf:"bytes,2,opt,name=Service,proto3" json:"Service,omitempty"` Checks []*HealthCheck `protobuf:"bytes,3,rep,name=Checks,proto3" json:"Checks,omitempty"` }
CheckServiceNode is used to provide the node, its service definition, as well as a HealthCheck that is associated.
func NewCheckServiceNodeFromStructs ¶
func NewCheckServiceNodeFromStructs(t *structs.CheckServiceNode) *CheckServiceNode
TODO: use mog once it supports pointers and slices
func (*CheckServiceNode) Descriptor ¶
func (*CheckServiceNode) Descriptor() ([]byte, []int)
func (*CheckServiceNode) Marshal ¶
func (m *CheckServiceNode) Marshal() (dAtA []byte, err error)
func (*CheckServiceNode) MarshalBinary ¶
func (msg *CheckServiceNode) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*CheckServiceNode) MarshalToSizedBuffer ¶
func (m *CheckServiceNode) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*CheckServiceNode) ProtoMessage ¶
func (*CheckServiceNode) ProtoMessage()
func (*CheckServiceNode) Reset ¶
func (m *CheckServiceNode) Reset()
func (*CheckServiceNode) Size ¶
func (m *CheckServiceNode) Size() (n int)
func (*CheckServiceNode) String ¶
func (m *CheckServiceNode) String() string
func (*CheckServiceNode) UniqueID ¶
func (m *CheckServiceNode) UniqueID() string
UniqueID returns a unique identifier for this CheckServiceNode, which includes the node name, service namespace, and service ID.
The returned ID uses slashes to separate the identifiers, however the node name may also contain a slash, so it is not possible to parse this identifier to retrieve its constituent parts.
This function is similar to structs.UniqueID, however at this time no guarantees are made that it will remain the same.
func (*CheckServiceNode) Unmarshal ¶
func (m *CheckServiceNode) Unmarshal(dAtA []byte) error
func (*CheckServiceNode) UnmarshalBinary ¶
func (msg *CheckServiceNode) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*CheckServiceNode) XXX_DiscardUnknown ¶
func (m *CheckServiceNode) XXX_DiscardUnknown()
func (*CheckServiceNode) XXX_Marshal ¶
func (m *CheckServiceNode) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*CheckServiceNode) XXX_Merge ¶
func (m *CheckServiceNode) XXX_Merge(src proto.Message)
func (*CheckServiceNode) XXX_Size ¶
func (m *CheckServiceNode) XXX_Size() int
func (*CheckServiceNode) XXX_Unmarshal ¶
func (m *CheckServiceNode) XXX_Unmarshal(b []byte) error
type CheckType ¶
type CheckType struct { CheckID github_com_hashicorp_consul_types.CheckID `protobuf:"bytes,1,opt,name=CheckID,proto3,casttype=github.com/hashicorp/consul/types.CheckID" json:"CheckID,omitempty"` Name string `protobuf:"bytes,2,opt,name=Name,proto3" json:"Name,omitempty"` Status string `protobuf:"bytes,3,opt,name=Status,proto3" json:"Status,omitempty"` Notes string `protobuf:"bytes,4,opt,name=Notes,proto3" json:"Notes,omitempty"` ScriptArgs []string `protobuf:"bytes,5,rep,name=ScriptArgs,proto3" json:"ScriptArgs,omitempty"` HTTP string `protobuf:"bytes,6,opt,name=HTTP,proto3" json:"HTTP,omitempty"` // mog: func-to=MapHeadersToStructs func-from=NewMapHeadersFromStructs Header map[string]HeaderValue `` /* 144-byte string literal not displayed */ Method string `protobuf:"bytes,7,opt,name=Method,proto3" json:"Method,omitempty"` Body string `protobuf:"bytes,26,opt,name=Body,proto3" json:"Body,omitempty"` DisableRedirects bool `protobuf:"varint,31,opt,name=DisableRedirects,proto3" json:"DisableRedirects,omitempty"` TCP string `protobuf:"bytes,8,opt,name=TCP,proto3" json:"TCP,omitempty"` Interval time.Duration `protobuf:"bytes,9,opt,name=Interval,proto3,stdduration" json:"Interval"` AliasNode string `protobuf:"bytes,10,opt,name=AliasNode,proto3" json:"AliasNode,omitempty"` AliasService string `protobuf:"bytes,11,opt,name=AliasService,proto3" json:"AliasService,omitempty"` DockerContainerID string `protobuf:"bytes,12,opt,name=DockerContainerID,proto3" json:"DockerContainerID,omitempty"` Shell string `protobuf:"bytes,13,opt,name=Shell,proto3" json:"Shell,omitempty"` GRPC string `protobuf:"bytes,14,opt,name=GRPC,proto3" json:"GRPC,omitempty"` GRPCUseTLS bool `protobuf:"varint,15,opt,name=GRPCUseTLS,proto3" json:"GRPCUseTLS,omitempty"` TLSSkipVerify bool `protobuf:"varint,16,opt,name=TLSSkipVerify,proto3" json:"TLSSkipVerify,omitempty"` Timeout time.Duration `protobuf:"bytes,17,opt,name=Timeout,proto3,stdduration" json:"Timeout"` TTL time.Duration `protobuf:"bytes,18,opt,name=TTL,proto3,stdduration" json:"TTL"` // mog: func-to=int func-from=int32 SuccessBeforePassing int32 `protobuf:"varint,21,opt,name=SuccessBeforePassing,proto3" json:"SuccessBeforePassing,omitempty"` // mog: func-to=int func-from=int32 FailuresBeforeCritical int32 `protobuf:"varint,22,opt,name=FailuresBeforeCritical,proto3" json:"FailuresBeforeCritical,omitempty"` // Definition fields used when exposing checks through a proxy ProxyHTTP string `protobuf:"bytes,23,opt,name=ProxyHTTP,proto3" json:"ProxyHTTP,omitempty"` ProxyGRPC string `protobuf:"bytes,24,opt,name=ProxyGRPC,proto3" json:"ProxyGRPC,omitempty"` // DeregisterCriticalServiceAfter, if >0, will cause the associated // service, if any, to be deregistered if this check is critical for // longer than this duration. DeregisterCriticalServiceAfter time.Duration `protobuf:"bytes,19,opt,name=DeregisterCriticalServiceAfter,proto3,stdduration" json:"DeregisterCriticalServiceAfter"` // mog: func-to=int func-from=int32 OutputMaxSize int32 `protobuf:"varint,25,opt,name=OutputMaxSize,proto3" json:"OutputMaxSize,omitempty"` }
CheckType is used to create either the CheckMonitor or the CheckTTL. The following types are supported: Script, HTTP, TCP, Docker, TTL, GRPC, Alias. Script, HTTP, Docker, TCP and GRPC all require Interval. Only one of the types may to be provided: TTL or Script/Interval or HTTP/Interval or TCP/Interval or Docker/Interval or GRPC/Interval or AliasService.
mog annotation:
target=github.com/hashicorp/consul/agent/structs.CheckType output=healthcheck.gen.go name=Structs
func NewCheckTypeFromStructs ¶
func NewCheckTypesFromStructs ¶
func NewCheckTypesFromStructs(t structs.CheckTypes) []*CheckType
TODO: handle this with mog
func (*CheckType) Descriptor ¶
func (*CheckType) MarshalBinary ¶
MarshalBinary implements encoding.BinaryMarshaler
func (*CheckType) MarshalToSizedBuffer ¶
func (*CheckType) ProtoMessage ¶
func (*CheckType) ProtoMessage()
func (*CheckType) UnmarshalBinary ¶
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*CheckType) XXX_DiscardUnknown ¶
func (m *CheckType) XXX_DiscardUnknown()
func (*CheckType) XXX_Marshal ¶
func (*CheckType) XXX_Unmarshal ¶
type ConnectProxyConfig ¶
type ConnectProxyConfig struct { // DestinationServiceName is required and is the name of the service to accept // traffic for. DestinationServiceName string `protobuf:"bytes,1,opt,name=DestinationServiceName,proto3" json:"DestinationServiceName,omitempty"` // DestinationServiceID is optional and should only be specified for // "side-car" style proxies where the proxy is in front of just a single // instance of the service. It should be set to the service ID of the instance // being represented which must be registered to the same agent. It's valid to // provide a service ID that does not yet exist to avoid timing issues when // bootstrapping a service with a proxy. DestinationServiceID string `protobuf:"bytes,2,opt,name=DestinationServiceID,proto3" json:"DestinationServiceID,omitempty"` // LocalServiceAddress is the address of the local service instance. It is // optional and should only be specified for "side-car" style proxies. It will // default to 127.0.0.1 if the proxy is a "side-car" (DestinationServiceID is // set) but otherwise will be ignored. LocalServiceAddress string `protobuf:"bytes,3,opt,name=LocalServiceAddress,proto3" json:"LocalServiceAddress,omitempty"` // LocalServicePort is the port of the local service instance. It is optional // and should only be specified for "side-car" style proxies. It will default // to the registered port for the instance if the proxy is a "side-car" // (DestinationServiceID is set) but otherwise will be ignored. // mog: func-to=int func-from=int32 LocalServicePort int32 `protobuf:"varint,4,opt,name=LocalServicePort,proto3" json:"LocalServicePort,omitempty"` // Config is the arbitrary configuration data provided with the proxy // registration. // mog: func-to=ProtobufTypesStructToMapStringInterface func-from=MapStringInterfaceToProtobufTypesStruct Config *types.Struct `protobuf:"bytes,5,opt,name=Config,proto3" json:"Config,omitempty"` // Upstreams describes any upstream dependencies the proxy instance should // setup. // mog: func-to=UpstreamsToStructs func-from=NewUpstreamsFromStructs Upstreams []Upstream `protobuf:"bytes,6,rep,name=Upstreams,proto3" json:"Upstreams"` // MeshGateway defines the mesh gateway configuration for this upstream MeshGateway MeshGatewayConfig `protobuf:"bytes,7,opt,name=MeshGateway,proto3" json:"MeshGateway"` // Expose defines whether checks or paths are exposed through the proxy Expose ExposeConfig `protobuf:"bytes,8,opt,name=Expose,proto3" json:"Expose"` }
ConnectProxyConfig describes the configuration needed for any proxy managed or unmanaged. It describes a single logical service's listener and optionally upstreams and sidecar-related config for a single instance. To describe a centralized proxy that routed traffic for multiple services, a different one of these would be needed for each, sharing the same LogicalProxyID.
mog annotation:
target=github.com/hashicorp/consul/agent/structs.ConnectProxyConfig output=service.gen.go name=Structs
func NewConnectProxyConfigFromStructs ¶
func NewConnectProxyConfigFromStructs(t structs.ConnectProxyConfig) ConnectProxyConfig
func NewConnectProxyConfigPtrFromStructs ¶
func NewConnectProxyConfigPtrFromStructs(t *structs.ConnectProxyConfig) *ConnectProxyConfig
TODO: handle this with mog
func (*ConnectProxyConfig) Descriptor ¶
func (*ConnectProxyConfig) Descriptor() ([]byte, []int)
func (*ConnectProxyConfig) Marshal ¶
func (m *ConnectProxyConfig) Marshal() (dAtA []byte, err error)
func (*ConnectProxyConfig) MarshalBinary ¶
func (msg *ConnectProxyConfig) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*ConnectProxyConfig) MarshalTo ¶
func (m *ConnectProxyConfig) MarshalTo(dAtA []byte) (int, error)
func (*ConnectProxyConfig) MarshalToSizedBuffer ¶
func (m *ConnectProxyConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ConnectProxyConfig) ProtoMessage ¶
func (*ConnectProxyConfig) ProtoMessage()
func (*ConnectProxyConfig) Reset ¶
func (m *ConnectProxyConfig) Reset()
func (*ConnectProxyConfig) Size ¶
func (m *ConnectProxyConfig) Size() (n int)
func (*ConnectProxyConfig) String ¶
func (m *ConnectProxyConfig) String() string
func (*ConnectProxyConfig) Unmarshal ¶
func (m *ConnectProxyConfig) Unmarshal(dAtA []byte) error
func (*ConnectProxyConfig) UnmarshalBinary ¶
func (msg *ConnectProxyConfig) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*ConnectProxyConfig) XXX_DiscardUnknown ¶
func (m *ConnectProxyConfig) XXX_DiscardUnknown()
func (*ConnectProxyConfig) XXX_Marshal ¶
func (m *ConnectProxyConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ConnectProxyConfig) XXX_Merge ¶
func (m *ConnectProxyConfig) XXX_Merge(src proto.Message)
func (*ConnectProxyConfig) XXX_Size ¶
func (m *ConnectProxyConfig) XXX_Size() int
func (*ConnectProxyConfig) XXX_Unmarshal ¶
func (m *ConnectProxyConfig) XXX_Unmarshal(b []byte) error
type ExposeConfig ¶
type ExposeConfig struct { // Checks defines whether paths associated with Consul checks will be exposed. // This flag triggers exposing all HTTP and GRPC check paths registered for the service. Checks bool `protobuf:"varint,1,opt,name=Checks,proto3" json:"Checks,omitempty"` // Paths is the list of paths exposed through the proxy. // mog: func-to=ExposePathSliceToStructs func-from=NewExposePathSliceFromStructs Paths []ExposePath `protobuf:"bytes,2,rep,name=Paths,proto3" json:"Paths"` }
ExposeConfig describes HTTP paths to expose through Envoy outside of Connect. Users can expose individual paths and/or all HTTP/GRPC paths for checks.
mog annotation:
target=github.com/hashicorp/consul/agent/structs.ExposeConfig output=service.gen.go name=Structs
func NewExposeConfigFromStructs ¶
func NewExposeConfigFromStructs(t structs.ExposeConfig) ExposeConfig
func (*ExposeConfig) Descriptor ¶
func (*ExposeConfig) Descriptor() ([]byte, []int)
func (*ExposeConfig) Marshal ¶
func (m *ExposeConfig) Marshal() (dAtA []byte, err error)
func (*ExposeConfig) MarshalBinary ¶
func (msg *ExposeConfig) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*ExposeConfig) MarshalToSizedBuffer ¶
func (m *ExposeConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ExposeConfig) ProtoMessage ¶
func (*ExposeConfig) ProtoMessage()
func (*ExposeConfig) Reset ¶
func (m *ExposeConfig) Reset()
func (*ExposeConfig) Size ¶
func (m *ExposeConfig) Size() (n int)
func (*ExposeConfig) String ¶
func (m *ExposeConfig) String() string
func (*ExposeConfig) Unmarshal ¶
func (m *ExposeConfig) Unmarshal(dAtA []byte) error
func (*ExposeConfig) UnmarshalBinary ¶
func (msg *ExposeConfig) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*ExposeConfig) XXX_DiscardUnknown ¶
func (m *ExposeConfig) XXX_DiscardUnknown()
func (*ExposeConfig) XXX_Marshal ¶
func (m *ExposeConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ExposeConfig) XXX_Merge ¶
func (m *ExposeConfig) XXX_Merge(src proto.Message)
func (*ExposeConfig) XXX_Size ¶
func (m *ExposeConfig) XXX_Size() int
func (*ExposeConfig) XXX_Unmarshal ¶
func (m *ExposeConfig) XXX_Unmarshal(b []byte) error
type ExposePath ¶
type ExposePath struct { // ListenerPort defines the port of the proxy's listener for exposed paths. // mog: func-to=int func-from=int32 ListenerPort int32 `protobuf:"varint,1,opt,name=ListenerPort,proto3" json:"ListenerPort,omitempty"` // ExposePath is the path to expose through the proxy, ie. "/metrics." Path string `protobuf:"bytes,2,opt,name=Path,proto3" json:"Path,omitempty"` // LocalPathPort is the port that the service is listening on for the given path. // mog: func-to=int func-from=int32 LocalPathPort int32 `protobuf:"varint,3,opt,name=LocalPathPort,proto3" json:"LocalPathPort,omitempty"` // Protocol describes the upstream's service protocol. // Valid values are "http" and "http2", defaults to "http" Protocol string `protobuf:"bytes,4,opt,name=Protocol,proto3" json:"Protocol,omitempty"` // ParsedFromCheck is set if this path was parsed from a registered check ParsedFromCheck bool `protobuf:"varint,5,opt,name=ParsedFromCheck,proto3" json:"ParsedFromCheck,omitempty"` }
mog annotation:
target=github.com/hashicorp/consul/agent/structs.ExposePath output=service.gen.go name=Structs
func NewExposePathFromStructs ¶
func NewExposePathFromStructs(t structs.ExposePath) ExposePath
func NewExposePathSliceFromStructs ¶
func NewExposePathSliceFromStructs(t []structs.ExposePath) []ExposePath
TODO: handle this with mog
func (*ExposePath) Descriptor ¶
func (*ExposePath) Descriptor() ([]byte, []int)
func (*ExposePath) Marshal ¶
func (m *ExposePath) Marshal() (dAtA []byte, err error)
func (*ExposePath) MarshalBinary ¶
func (msg *ExposePath) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*ExposePath) MarshalToSizedBuffer ¶
func (m *ExposePath) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ExposePath) ProtoMessage ¶
func (*ExposePath) ProtoMessage()
func (*ExposePath) Reset ¶
func (m *ExposePath) Reset()
func (*ExposePath) Size ¶
func (m *ExposePath) Size() (n int)
func (*ExposePath) String ¶
func (m *ExposePath) String() string
func (*ExposePath) Unmarshal ¶
func (m *ExposePath) Unmarshal(dAtA []byte) error
func (*ExposePath) UnmarshalBinary ¶
func (msg *ExposePath) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*ExposePath) XXX_DiscardUnknown ¶
func (m *ExposePath) XXX_DiscardUnknown()
func (*ExposePath) XXX_Marshal ¶
func (m *ExposePath) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ExposePath) XXX_Merge ¶
func (m *ExposePath) XXX_Merge(src proto.Message)
func (*ExposePath) XXX_Size ¶
func (m *ExposePath) XXX_Size() int
func (*ExposePath) XXX_Unmarshal ¶
func (m *ExposePath) XXX_Unmarshal(b []byte) error
type HeaderValue ¶
type HeaderValue struct {
Value []string `protobuf:"bytes,1,rep,name=Value,proto3" json:"Value,omitempty"`
}
func (*HeaderValue) Descriptor ¶
func (*HeaderValue) Descriptor() ([]byte, []int)
func (*HeaderValue) Marshal ¶
func (m *HeaderValue) Marshal() (dAtA []byte, err error)
func (*HeaderValue) MarshalBinary ¶
func (msg *HeaderValue) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*HeaderValue) MarshalToSizedBuffer ¶
func (m *HeaderValue) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*HeaderValue) ProtoMessage ¶
func (*HeaderValue) ProtoMessage()
func (*HeaderValue) Reset ¶
func (m *HeaderValue) Reset()
func (*HeaderValue) Size ¶
func (m *HeaderValue) Size() (n int)
func (*HeaderValue) String ¶
func (m *HeaderValue) String() string
func (*HeaderValue) Unmarshal ¶
func (m *HeaderValue) Unmarshal(dAtA []byte) error
func (*HeaderValue) UnmarshalBinary ¶
func (msg *HeaderValue) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*HeaderValue) XXX_DiscardUnknown ¶
func (m *HeaderValue) XXX_DiscardUnknown()
func (*HeaderValue) XXX_Marshal ¶
func (m *HeaderValue) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*HeaderValue) XXX_Merge ¶
func (m *HeaderValue) XXX_Merge(src proto.Message)
func (*HeaderValue) XXX_Size ¶
func (m *HeaderValue) XXX_Size() int
func (*HeaderValue) XXX_Unmarshal ¶
func (m *HeaderValue) XXX_Unmarshal(b []byte) error
type HealthCheck ¶
type HealthCheck struct { Node string `protobuf:"bytes,1,opt,name=Node,proto3" json:"Node,omitempty"` CheckID github_com_hashicorp_consul_types.CheckID `protobuf:"bytes,2,opt,name=CheckID,proto3,casttype=github.com/hashicorp/consul/types.CheckID" json:"CheckID,omitempty"` Name string `protobuf:"bytes,3,opt,name=Name,proto3" json:"Name,omitempty"` Status string `protobuf:"bytes,4,opt,name=Status,proto3" json:"Status,omitempty"` Notes string `protobuf:"bytes,5,opt,name=Notes,proto3" json:"Notes,omitempty"` Output string `protobuf:"bytes,6,opt,name=Output,proto3" json:"Output,omitempty"` ServiceID string `protobuf:"bytes,7,opt,name=ServiceID,proto3" json:"ServiceID,omitempty"` ServiceName string `protobuf:"bytes,8,opt,name=ServiceName,proto3" json:"ServiceName,omitempty"` ServiceTags []string `protobuf:"bytes,9,rep,name=ServiceTags,proto3" json:"ServiceTags,omitempty"` Type string `protobuf:"bytes,12,opt,name=Type,proto3" json:"Type,omitempty"` Definition HealthCheckDefinition `protobuf:"bytes,10,opt,name=Definition,proto3" json:"Definition"` // mog: func-to=RaftIndexToStructs func-from=NewRaftIndexFromStructs pbcommon.RaftIndex `protobuf:"bytes,11,opt,name=RaftIndex,proto3,embedded=RaftIndex" json:"RaftIndex"` // mog: func-to=EnterpriseMetaToStructs func-from=NewEnterpriseMetaFromStructs EnterpriseMeta pbcommon.EnterpriseMeta `protobuf:"bytes,13,opt,name=EnterpriseMeta,proto3" json:"EnterpriseMeta"` }
HealthCheck represents a single check on a given node
mog annotation:
target=github.com/hashicorp/consul/agent/structs.HealthCheck output=healthcheck.gen.go name=Structs
func NewHealthCheckFromStructs ¶
func NewHealthCheckFromStructs(t structs.HealthCheck) HealthCheck
func (*HealthCheck) Descriptor ¶
func (*HealthCheck) Descriptor() ([]byte, []int)
func (*HealthCheck) Marshal ¶
func (m *HealthCheck) Marshal() (dAtA []byte, err error)
func (*HealthCheck) MarshalBinary ¶
func (msg *HealthCheck) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*HealthCheck) MarshalToSizedBuffer ¶
func (m *HealthCheck) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*HealthCheck) ProtoMessage ¶
func (*HealthCheck) ProtoMessage()
func (*HealthCheck) Reset ¶
func (m *HealthCheck) Reset()
func (*HealthCheck) Size ¶
func (m *HealthCheck) Size() (n int)
func (*HealthCheck) String ¶
func (m *HealthCheck) String() string
func (*HealthCheck) Unmarshal ¶
func (m *HealthCheck) Unmarshal(dAtA []byte) error
func (*HealthCheck) UnmarshalBinary ¶
func (msg *HealthCheck) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*HealthCheck) XXX_DiscardUnknown ¶
func (m *HealthCheck) XXX_DiscardUnknown()
func (*HealthCheck) XXX_Marshal ¶
func (m *HealthCheck) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*HealthCheck) XXX_Merge ¶
func (m *HealthCheck) XXX_Merge(src proto.Message)
func (*HealthCheck) XXX_Size ¶
func (m *HealthCheck) XXX_Size() int
func (*HealthCheck) XXX_Unmarshal ¶
func (m *HealthCheck) XXX_Unmarshal(b []byte) error
type HealthCheckDefinition ¶
type HealthCheckDefinition struct { HTTP string `protobuf:"bytes,1,opt,name=HTTP,proto3" json:"HTTP,omitempty"` TLSSkipVerify bool `protobuf:"varint,2,opt,name=TLSSkipVerify,proto3" json:"TLSSkipVerify,omitempty"` // mog: func-to=MapHeadersToStructs func-from=NewMapHeadersFromStructs Header map[string]HeaderValue `` /* 143-byte string literal not displayed */ Method string `protobuf:"bytes,4,opt,name=Method,proto3" json:"Method,omitempty"` Body string `protobuf:"bytes,18,opt,name=Body,proto3" json:"Body,omitempty"` DisableRedirects bool `protobuf:"varint,22,opt,name=DisableRedirects,proto3" json:"DisableRedirects,omitempty"` TCP string `protobuf:"bytes,5,opt,name=TCP,proto3" json:"TCP,omitempty"` Interval time.Duration `protobuf:"bytes,6,opt,name=Interval,proto3,stdduration" json:"Interval"` // mog: func-to=uint func-from=uint32 OutputMaxSize uint32 `protobuf:"varint,9,opt,name=OutputMaxSize,proto3" json:"OutputMaxSize,omitempty"` Timeout time.Duration `protobuf:"bytes,7,opt,name=Timeout,proto3,stdduration" json:"Timeout"` DeregisterCriticalServiceAfter time.Duration `protobuf:"bytes,8,opt,name=DeregisterCriticalServiceAfter,proto3,stdduration" json:"DeregisterCriticalServiceAfter"` ScriptArgs []string `protobuf:"bytes,10,rep,name=ScriptArgs,proto3" json:"ScriptArgs,omitempty"` DockerContainerID string `protobuf:"bytes,11,opt,name=DockerContainerID,proto3" json:"DockerContainerID,omitempty"` Shell string `protobuf:"bytes,12,opt,name=Shell,proto3" json:"Shell,omitempty"` GRPC string `protobuf:"bytes,13,opt,name=GRPC,proto3" json:"GRPC,omitempty"` GRPCUseTLS bool `protobuf:"varint,14,opt,name=GRPCUseTLS,proto3" json:"GRPCUseTLS,omitempty"` AliasNode string `protobuf:"bytes,15,opt,name=AliasNode,proto3" json:"AliasNode,omitempty"` AliasService string `protobuf:"bytes,16,opt,name=AliasService,proto3" json:"AliasService,omitempty"` TTL time.Duration `protobuf:"bytes,17,opt,name=TTL,proto3,stdduration" json:"TTL"` }
HealthCheckDefinition of a single HealthCheck.
mog annotation:
target=github.com/hashicorp/consul/agent/structs.HealthCheckDefinition output=healthcheck.gen.go name=Structs
func NewHealthCheckDefinitionFromStructs ¶
func NewHealthCheckDefinitionFromStructs(t structs.HealthCheckDefinition) HealthCheckDefinition
func (*HealthCheckDefinition) Descriptor ¶
func (*HealthCheckDefinition) Descriptor() ([]byte, []int)
func (*HealthCheckDefinition) Marshal ¶
func (m *HealthCheckDefinition) Marshal() (dAtA []byte, err error)
func (*HealthCheckDefinition) MarshalBinary ¶
func (msg *HealthCheckDefinition) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*HealthCheckDefinition) MarshalTo ¶
func (m *HealthCheckDefinition) MarshalTo(dAtA []byte) (int, error)
func (*HealthCheckDefinition) MarshalToSizedBuffer ¶
func (m *HealthCheckDefinition) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*HealthCheckDefinition) ProtoMessage ¶
func (*HealthCheckDefinition) ProtoMessage()
func (*HealthCheckDefinition) Reset ¶
func (m *HealthCheckDefinition) Reset()
func (*HealthCheckDefinition) Size ¶
func (m *HealthCheckDefinition) Size() (n int)
func (*HealthCheckDefinition) String ¶
func (m *HealthCheckDefinition) String() string
func (*HealthCheckDefinition) Unmarshal ¶
func (m *HealthCheckDefinition) Unmarshal(dAtA []byte) error
func (*HealthCheckDefinition) UnmarshalBinary ¶
func (msg *HealthCheckDefinition) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*HealthCheckDefinition) XXX_DiscardUnknown ¶
func (m *HealthCheckDefinition) XXX_DiscardUnknown()
func (*HealthCheckDefinition) XXX_Marshal ¶
func (m *HealthCheckDefinition) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*HealthCheckDefinition) XXX_Merge ¶
func (m *HealthCheckDefinition) XXX_Merge(src proto.Message)
func (*HealthCheckDefinition) XXX_Size ¶
func (m *HealthCheckDefinition) XXX_Size() int
func (*HealthCheckDefinition) XXX_Unmarshal ¶
func (m *HealthCheckDefinition) XXX_Unmarshal(b []byte) error
type MeshGatewayConfig ¶
type MeshGatewayConfig struct {
Mode github_com_hashicorp_consul_agent_structs.MeshGatewayMode `` /* 128-byte string literal not displayed */
}
mog annotation:
target=github.com/hashicorp/consul/agent/structs.MeshGatewayConfig output=service.gen.go name=Structs
func NewMeshGatewayConfigFromStructs ¶
func NewMeshGatewayConfigFromStructs(t structs.MeshGatewayConfig) MeshGatewayConfig
func (*MeshGatewayConfig) Descriptor ¶
func (*MeshGatewayConfig) Descriptor() ([]byte, []int)
func (*MeshGatewayConfig) Marshal ¶
func (m *MeshGatewayConfig) Marshal() (dAtA []byte, err error)
func (*MeshGatewayConfig) MarshalBinary ¶
func (msg *MeshGatewayConfig) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*MeshGatewayConfig) MarshalTo ¶
func (m *MeshGatewayConfig) MarshalTo(dAtA []byte) (int, error)
func (*MeshGatewayConfig) MarshalToSizedBuffer ¶
func (m *MeshGatewayConfig) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MeshGatewayConfig) ProtoMessage ¶
func (*MeshGatewayConfig) ProtoMessage()
func (*MeshGatewayConfig) Reset ¶
func (m *MeshGatewayConfig) Reset()
func (*MeshGatewayConfig) Size ¶
func (m *MeshGatewayConfig) Size() (n int)
func (*MeshGatewayConfig) String ¶
func (m *MeshGatewayConfig) String() string
func (*MeshGatewayConfig) Unmarshal ¶
func (m *MeshGatewayConfig) Unmarshal(dAtA []byte) error
func (*MeshGatewayConfig) UnmarshalBinary ¶
func (msg *MeshGatewayConfig) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*MeshGatewayConfig) XXX_DiscardUnknown ¶
func (m *MeshGatewayConfig) XXX_DiscardUnknown()
func (*MeshGatewayConfig) XXX_Marshal ¶
func (m *MeshGatewayConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MeshGatewayConfig) XXX_Merge ¶
func (m *MeshGatewayConfig) XXX_Merge(src proto.Message)
func (*MeshGatewayConfig) XXX_Size ¶
func (m *MeshGatewayConfig) XXX_Size() int
func (*MeshGatewayConfig) XXX_Unmarshal ¶
func (m *MeshGatewayConfig) XXX_Unmarshal(b []byte) error
type Node ¶
type Node struct { ID github_com_hashicorp_consul_types.NodeID `protobuf:"bytes,1,opt,name=ID,proto3,casttype=github.com/hashicorp/consul/types.NodeID" json:"ID,omitempty"` Node string `protobuf:"bytes,2,opt,name=Node,proto3" json:"Node,omitempty"` Address string `protobuf:"bytes,3,opt,name=Address,proto3" json:"Address,omitempty"` Datacenter string `protobuf:"bytes,4,opt,name=Datacenter,proto3" json:"Datacenter,omitempty"` TaggedAddresses map[string]string `` /* 171-byte string literal not displayed */ Meta map[string]string `` /* 149-byte string literal not displayed */ // mog: func-to=RaftIndexToStructs func-from=NewRaftIndexFromStructs pbcommon.RaftIndex `protobuf:"bytes,7,opt,name=RaftIndex,proto3,embedded=RaftIndex" json:"RaftIndex"` }
Node contains information about a node.
mog annotation:
target=github.com/hashicorp/consul/agent/structs.Node output=node.gen.go name=Structs
func NewNodeFromStructs ¶
func (*Node) Descriptor ¶
func (*Node) MarshalBinary ¶
MarshalBinary implements encoding.BinaryMarshaler
func (*Node) ProtoMessage ¶
func (*Node) ProtoMessage()
func (*Node) UnmarshalBinary ¶
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*Node) XXX_DiscardUnknown ¶
func (m *Node) XXX_DiscardUnknown()
func (*Node) XXX_Unmarshal ¶
type NodeService ¶
type NodeService struct { // Kind is the kind of service this is. Different kinds of services may // have differing validation, DNS behavior, etc. An empty kind will default // to the Default kind. See ServiceKind for the full list of kinds. Kind github_com_hashicorp_consul_agent_structs.ServiceKind `protobuf:"bytes,1,opt,name=Kind,proto3,casttype=github.com/hashicorp/consul/agent/structs.ServiceKind" json:"Kind,omitempty"` ID string `protobuf:"bytes,2,opt,name=ID,proto3" json:"ID,omitempty"` Service string `protobuf:"bytes,3,opt,name=Service,proto3" json:"Service,omitempty"` Tags []string `protobuf:"bytes,4,rep,name=Tags,proto3" json:"Tags,omitempty"` Address string `protobuf:"bytes,5,opt,name=Address,proto3" json:"Address,omitempty"` // mog: func-to=MapStringServiceAddressToStructs func-from=NewMapStringServiceAddressFromStructs TaggedAddresses map[string]ServiceAddress `` /* 162-byte string literal not displayed */ Meta map[string]string `` /* 149-byte string literal not displayed */ // mog: func-to=int func-from=int32 Port int32 `protobuf:"varint,7,opt,name=Port,proto3" json:"Port,omitempty"` // mog: func-to=WeightsPtrToStructs func-from=NewWeightsPtrFromStructs Weights *Weights `protobuf:"bytes,8,opt,name=Weights,proto3" json:"Weights,omitempty"` EnableTagOverride bool `protobuf:"varint,9,opt,name=EnableTagOverride,proto3" json:"EnableTagOverride,omitempty"` // Proxy is the configuration set for Kind = connect-proxy. It is mandatory in // that case and an error to be set for any other kind. This config is part of // a proxy service definition and is distinct from but shares some fields with // the Connect.Proxy which configures a managed proxy as part of the actual // service's definition. This duplication is ugly but seemed better than the // alternative which was to re-use the same struct fields for both cases even // though the semantics are different and the non-shred fields make no sense // in the other case. ProxyConfig may be a more natural name here, but it's // confusing for the UX because one of the fields in ConnectProxyConfig is // also called just "Config" Proxy ConnectProxyConfig `protobuf:"bytes,11,opt,name=Proxy,proto3" json:"Proxy"` // Connect are the Connect settings for a service. This is purposely NOT // a pointer so that we never have to nil-check this. Connect ServiceConnect `protobuf:"bytes,12,opt,name=Connect,proto3" json:"Connect"` // LocallyRegisteredAsSidecar is private as it is only used by a local agent // state to track if the service was registered from a nested sidecar_service // block. We need to track that so we can know whether we need to deregister // it automatically too if it's removed from the service definition or if the // parent service is deregistered. Relying only on ID would cause us to // deregister regular services if they happen to be registered using the same // ID scheme as our sidecars do by default. We could use meta but that gets // unpleasant because we can't use the consul- prefix from an agent (reserved // for use internally but in practice that means within the state store or in // responses only), and it leaks the detail publicly which people might rely // on which is a bit unpleasant for something that is meant to be config-file // syntax sugar. Note this is not translated to ServiceNode and friends and // may not be set on a NodeService that isn't the one the agent registered and // keeps in it's local state. We never want this rendered in JSON as it's // internal only. Right now our agent endpoints return api structs which don't // include it but this is a safety net incase we change that or there is // somewhere this is used in API output. LocallyRegisteredAsSidecar bool `protobuf:"varint,13,opt,name=LocallyRegisteredAsSidecar,proto3" json:"LocallyRegisteredAsSidecar,omitempty"` // mog: func-to=EnterpriseMetaToStructs func-from=NewEnterpriseMetaFromStructs EnterpriseMeta pbcommon.EnterpriseMeta `protobuf:"bytes,16,opt,name=EnterpriseMeta,proto3" json:"EnterpriseMeta"` // mog: func-to=RaftIndexToStructs func-from=NewRaftIndexFromStructs pbcommon.RaftIndex `protobuf:"bytes,14,opt,name=RaftIndex,proto3,embedded=RaftIndex" json:"RaftIndex"` }
NodeService is a service provided by a node
mog annotation:
target=github.com/hashicorp/consul/agent/structs.NodeService output=node.gen.go name=Structs
func NewNodeServiceFromStructs ¶
func NewNodeServiceFromStructs(t structs.NodeService) NodeService
func (*NodeService) Descriptor ¶
func (*NodeService) Descriptor() ([]byte, []int)
func (*NodeService) Marshal ¶
func (m *NodeService) Marshal() (dAtA []byte, err error)
func (*NodeService) MarshalBinary ¶
func (msg *NodeService) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*NodeService) MarshalToSizedBuffer ¶
func (m *NodeService) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*NodeService) ProtoMessage ¶
func (*NodeService) ProtoMessage()
func (*NodeService) Reset ¶
func (m *NodeService) Reset()
func (*NodeService) Size ¶
func (m *NodeService) Size() (n int)
func (*NodeService) String ¶
func (m *NodeService) String() string
func (*NodeService) Unmarshal ¶
func (m *NodeService) Unmarshal(dAtA []byte) error
func (*NodeService) UnmarshalBinary ¶
func (msg *NodeService) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*NodeService) XXX_DiscardUnknown ¶
func (m *NodeService) XXX_DiscardUnknown()
func (*NodeService) XXX_Marshal ¶
func (m *NodeService) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*NodeService) XXX_Merge ¶
func (m *NodeService) XXX_Merge(src proto.Message)
func (*NodeService) XXX_Size ¶
func (m *NodeService) XXX_Size() int
func (*NodeService) XXX_Unmarshal ¶
func (m *NodeService) XXX_Unmarshal(b []byte) error
type ServiceAddress ¶
type ServiceAddress struct { Address string `protobuf:"bytes,1,opt,name=Address,proto3" json:"Address,omitempty"` // mog: func-to=int func-from=int32 Port int32 `protobuf:"varint,2,opt,name=Port,proto3" json:"Port,omitempty"` }
Type to hold an address and port of a service
func (*ServiceAddress) Descriptor ¶
func (*ServiceAddress) Descriptor() ([]byte, []int)
func (*ServiceAddress) Marshal ¶
func (m *ServiceAddress) Marshal() (dAtA []byte, err error)
func (*ServiceAddress) MarshalBinary ¶
func (msg *ServiceAddress) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*ServiceAddress) MarshalToSizedBuffer ¶
func (m *ServiceAddress) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ServiceAddress) ProtoMessage ¶
func (*ServiceAddress) ProtoMessage()
func (*ServiceAddress) Reset ¶
func (m *ServiceAddress) Reset()
func (*ServiceAddress) Size ¶
func (m *ServiceAddress) Size() (n int)
func (*ServiceAddress) String ¶
func (m *ServiceAddress) String() string
func (*ServiceAddress) Unmarshal ¶
func (m *ServiceAddress) Unmarshal(dAtA []byte) error
func (*ServiceAddress) UnmarshalBinary ¶
func (msg *ServiceAddress) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*ServiceAddress) XXX_DiscardUnknown ¶
func (m *ServiceAddress) XXX_DiscardUnknown()
func (*ServiceAddress) XXX_Marshal ¶
func (m *ServiceAddress) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ServiceAddress) XXX_Merge ¶
func (m *ServiceAddress) XXX_Merge(src proto.Message)
func (*ServiceAddress) XXX_Size ¶
func (m *ServiceAddress) XXX_Size() int
func (*ServiceAddress) XXX_Unmarshal ¶
func (m *ServiceAddress) XXX_Unmarshal(b []byte) error
type ServiceConnect ¶
type ServiceConnect struct { // Native is true when this service can natively understand Connect. Native bool `protobuf:"varint,1,opt,name=Native,proto3" json:"Native,omitempty"` // SidecarService is a nested Service Definition to register at the same time. // It's purely a convenience mechanism to allow specifying a sidecar service // along with the application service definition. It's nested nature allows // all of the fields to be defaulted which can reduce the amount of // boilerplate needed to register a sidecar service separately, but the end // result is identical to just making a second service registration via any // other means. // mog: func-to=ServiceDefinitionPtrToStructs func-from=NewServiceDefinitionPtrFromStructs SidecarService *ServiceDefinition `protobuf:"bytes,3,opt,name=SidecarService,proto3" json:"SidecarService,omitempty"` }
ServiceConnect are the shared Connect settings between all service definitions from the agent to the state store. mog annotation:
target=github.com/hashicorp/consul/agent/structs.ServiceConnect output=service.gen.go name=Structs
func NewServiceConnectFromStructs ¶
func NewServiceConnectFromStructs(t structs.ServiceConnect) ServiceConnect
func NewServiceConnectPtrFromStructs ¶
func NewServiceConnectPtrFromStructs(t *structs.ServiceConnect) *ServiceConnect
TODO: handle this with mog
func (*ServiceConnect) Descriptor ¶
func (*ServiceConnect) Descriptor() ([]byte, []int)
func (*ServiceConnect) Marshal ¶
func (m *ServiceConnect) Marshal() (dAtA []byte, err error)
func (*ServiceConnect) MarshalBinary ¶
func (msg *ServiceConnect) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*ServiceConnect) MarshalToSizedBuffer ¶
func (m *ServiceConnect) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ServiceConnect) ProtoMessage ¶
func (*ServiceConnect) ProtoMessage()
func (*ServiceConnect) Reset ¶
func (m *ServiceConnect) Reset()
func (*ServiceConnect) Size ¶
func (m *ServiceConnect) Size() (n int)
func (*ServiceConnect) String ¶
func (m *ServiceConnect) String() string
func (*ServiceConnect) Unmarshal ¶
func (m *ServiceConnect) Unmarshal(dAtA []byte) error
func (*ServiceConnect) UnmarshalBinary ¶
func (msg *ServiceConnect) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*ServiceConnect) XXX_DiscardUnknown ¶
func (m *ServiceConnect) XXX_DiscardUnknown()
func (*ServiceConnect) XXX_Marshal ¶
func (m *ServiceConnect) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ServiceConnect) XXX_Merge ¶
func (m *ServiceConnect) XXX_Merge(src proto.Message)
func (*ServiceConnect) XXX_Size ¶
func (m *ServiceConnect) XXX_Size() int
func (*ServiceConnect) XXX_Unmarshal ¶
func (m *ServiceConnect) XXX_Unmarshal(b []byte) error
type ServiceDefinition ¶
type ServiceDefinition struct { Kind github_com_hashicorp_consul_agent_structs.ServiceKind `protobuf:"bytes,1,opt,name=Kind,proto3,casttype=github.com/hashicorp/consul/agent/structs.ServiceKind" json:"Kind,omitempty"` ID string `protobuf:"bytes,2,opt,name=ID,proto3" json:"ID,omitempty"` Name string `protobuf:"bytes,3,opt,name=Name,proto3" json:"Name,omitempty"` Tags []string `protobuf:"bytes,4,rep,name=Tags,proto3" json:"Tags,omitempty"` Address string `protobuf:"bytes,5,opt,name=Address,proto3" json:"Address,omitempty"` // mog: func-to=MapStringServiceAddressToStructs func-from=NewMapStringServiceAddressFromStructs TaggedAddresses map[string]ServiceAddress `` /* 162-byte string literal not displayed */ Meta map[string]string `` /* 149-byte string literal not displayed */ // mog: func-to=int func-from=int32 Port int32 `protobuf:"varint,7,opt,name=Port,proto3" json:"Port,omitempty"` Check CheckType `protobuf:"bytes,8,opt,name=Check,proto3" json:"Check"` // mog: func-to=CheckTypesToStructs func-from=NewCheckTypesFromStructs Checks []*CheckType `protobuf:"bytes,9,rep,name=Checks,proto3" json:"Checks,omitempty"` // mog: func-to=WeightsPtrToStructs func-from=NewWeightsPtrFromStructs Weights *Weights `protobuf:"bytes,10,opt,name=Weights,proto3" json:"Weights,omitempty"` Token string `protobuf:"bytes,11,opt,name=Token,proto3" json:"Token,omitempty"` EnableTagOverride bool `protobuf:"varint,12,opt,name=EnableTagOverride,proto3" json:"EnableTagOverride,omitempty"` // Proxy is the configuration set for Kind = connect-proxy. It is mandatory in // that case and an error to be set for any other kind. This config is part of // a proxy service definition and is distinct from but shares some fields with // the Connect.Proxy which configures a managed proxy as part of the actual // service's definition. This duplication is ugly but seemed better than the // alternative which was to re-use the same struct fields for both cases even // though the semantics are different and the non-shared fields make no sense // in the other case. ProxyConfig may be a more natural name here, but it's // confusing for the UX because one of the fields in ConnectProxyConfig is // also called just "Config" // mog: func-to=ConnectProxyConfigPtrToStructs func-from=NewConnectProxyConfigPtrFromStructs Proxy *ConnectProxyConfig `protobuf:"bytes,14,opt,name=Proxy,proto3" json:"Proxy,omitempty"` // mog: func-to=EnterpriseMetaToStructs func-from=NewEnterpriseMetaFromStructs EnterpriseMeta pbcommon.EnterpriseMeta `protobuf:"bytes,17,opt,name=EnterpriseMeta,proto3" json:"EnterpriseMeta"` // mog: func-to=ServiceConnectPtrToStructs func-from=NewServiceConnectPtrFromStructs Connect *ServiceConnect `protobuf:"bytes,15,opt,name=Connect,proto3" json:"Connect,omitempty"` }
ServiceDefinition is used to JSON decode the Service definitions. For documentation on specific fields see NodeService which is better documented.
mog annotation:
target=github.com/hashicorp/consul/agent/structs.ServiceDefinition output=service.gen.go name=Structs
func NewServiceDefinitionFromStructs ¶
func NewServiceDefinitionFromStructs(t structs.ServiceDefinition) ServiceDefinition
func NewServiceDefinitionPtrFromStructs ¶
func NewServiceDefinitionPtrFromStructs(t *structs.ServiceDefinition) *ServiceDefinition
TODO: handle this with mog
func (*ServiceDefinition) Descriptor ¶
func (*ServiceDefinition) Descriptor() ([]byte, []int)
func (*ServiceDefinition) Marshal ¶
func (m *ServiceDefinition) Marshal() (dAtA []byte, err error)
func (*ServiceDefinition) MarshalBinary ¶
func (msg *ServiceDefinition) MarshalBinary() ([]byte, error)
MarshalBinary implements encoding.BinaryMarshaler
func (*ServiceDefinition) MarshalTo ¶
func (m *ServiceDefinition) MarshalTo(dAtA []byte) (int, error)
func (*ServiceDefinition) MarshalToSizedBuffer ¶
func (m *ServiceDefinition) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ServiceDefinition) ProtoMessage ¶
func (*ServiceDefinition) ProtoMessage()
func (*ServiceDefinition) Reset ¶
func (m *ServiceDefinition) Reset()
func (*ServiceDefinition) Size ¶
func (m *ServiceDefinition) Size() (n int)
func (*ServiceDefinition) String ¶
func (m *ServiceDefinition) String() string
func (*ServiceDefinition) Unmarshal ¶
func (m *ServiceDefinition) Unmarshal(dAtA []byte) error
func (*ServiceDefinition) UnmarshalBinary ¶
func (msg *ServiceDefinition) UnmarshalBinary(b []byte) error
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*ServiceDefinition) XXX_DiscardUnknown ¶
func (m *ServiceDefinition) XXX_DiscardUnknown()
func (*ServiceDefinition) XXX_Marshal ¶
func (m *ServiceDefinition) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ServiceDefinition) XXX_Merge ¶
func (m *ServiceDefinition) XXX_Merge(src proto.Message)
func (*ServiceDefinition) XXX_Size ¶
func (m *ServiceDefinition) XXX_Size() int
func (*ServiceDefinition) XXX_Unmarshal ¶
func (m *ServiceDefinition) XXX_Unmarshal(b []byte) error
type Upstream ¶
type Upstream struct { // Destination fields are the required ones for determining what this upstream // points to. Depending on DestinationType some other fields below might // further restrict the set of instances allowable. // // DestinationType would be better as an int constant but even with custom // JSON marshallers it causes havoc with all the mapstructure mangling we do // on service definitions in various places. DestinationType string `protobuf:"bytes,1,opt,name=DestinationType,proto3" json:"DestinationType,omitempty"` DestinationNamespace string `protobuf:"bytes,2,opt,name=DestinationNamespace,proto3" json:"DestinationNamespace,omitempty"` DestinationName string `protobuf:"bytes,3,opt,name=DestinationName,proto3" json:"DestinationName,omitempty"` // Datacenter that the service discovery request should be run against. Note // for prepared queries, the actual results might be from a different // datacenter. Datacenter string `protobuf:"bytes,4,opt,name=Datacenter,proto3" json:"Datacenter,omitempty"` // LocalBindAddress is the ip address a side-car proxy should listen on for // traffic destined for this upstream service. Default if empty is 127.0.0.1. LocalBindAddress string `protobuf:"bytes,5,opt,name=LocalBindAddress,proto3" json:"LocalBindAddress,omitempty"` // LocalBindPort is the ip address a side-car proxy should listen on for // traffic destined for this upstream service. Required. // mog: func-to=int func-from=int32 LocalBindPort int32 `protobuf:"varint,6,opt,name=LocalBindPort,proto3" json:"LocalBindPort,omitempty"` // Config is an opaque config that is specific to the proxy process being run. // It can be used to pass arbitrary configuration for this specific upstream // to the proxy. // mog: func-to=ProtobufTypesStructToMapStringInterface func-from=MapStringInterfaceToProtobufTypesStruct Config *types.Struct `protobuf:"bytes,7,opt,name=Config,proto3" json:"Config,omitempty"` // MeshGateway is the configuration for mesh gateway usage of this upstream MeshGateway MeshGatewayConfig `protobuf:"bytes,8,opt,name=MeshGateway,proto3" json:"MeshGateway"` }
Upstream represents a single upstream dependency for a service or proxy. It describes the mechanism used to discover instances to communicate with (the Target) as well as any potential client configuration that may be useful such as load balancer options, timeouts etc.
mog annotation:
target=github.com/hashicorp/consul/agent/structs.Upstream output=service.gen.go name=Structs ignore-fields=IngressHosts
func NewUpstreamFromStructs ¶
func NewUpstreamsFromStructs ¶
TODO: handle this with mog
func (*Upstream) Descriptor ¶
func (*Upstream) MarshalBinary ¶
MarshalBinary implements encoding.BinaryMarshaler
func (*Upstream) MarshalToSizedBuffer ¶
func (*Upstream) ProtoMessage ¶
func (*Upstream) ProtoMessage()
func (*Upstream) UnmarshalBinary ¶
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*Upstream) XXX_DiscardUnknown ¶
func (m *Upstream) XXX_DiscardUnknown()
func (*Upstream) XXX_Marshal ¶
func (*Upstream) XXX_Unmarshal ¶
type Weights ¶
type Weights struct { // mog: func-to=int func-from=int32 Passing int32 `protobuf:"varint,1,opt,name=Passing,proto3" json:"Passing,omitempty"` // mog: func-to=int func-from=int32 Warning int32 `protobuf:"varint,2,opt,name=Warning,proto3" json:"Warning,omitempty"` }
Weights represent the weight used by DNS for a given status
func NewWeightsPtrFromStructs ¶
TODO: handle this with mog, once mog handles pointers
func (*Weights) Descriptor ¶
func (*Weights) MarshalBinary ¶
MarshalBinary implements encoding.BinaryMarshaler
func (*Weights) MarshalToSizedBuffer ¶
func (*Weights) ProtoMessage ¶
func (*Weights) ProtoMessage()
func (*Weights) UnmarshalBinary ¶
UnmarshalBinary implements encoding.BinaryUnmarshaler
func (*Weights) XXX_DiscardUnknown ¶
func (m *Weights) XXX_DiscardUnknown()