Documentation ¶
Index ¶
- func AddPrefixToNames(rs []model.Resource, prefix string)
- func AddPrefixToResourceKeyNames(rk []model.ResourceKey, prefix string) []model.ResourceKey
- func AddSuffixToNames(rs []model.Resource, suffix string)
- func AddSuffixToResourceKeyNames(rk []model.ResourceKey, suffix string) []model.ResourceKey
- func ClientIDFromIncomingCtx(ctx context.Context) (string, error)
- func CloneResourceMeta(m model.ResourceMeta, fs ...CloneResourceMetaOpt) model.ResourceMeta
- func DubboResourceMetaToResourceMeta(meta *mesh_proto.DubboResource_Meta) model.ResourceMeta
- func GetSupportedTypes() []string
- func MetadataFromIncomingCtx(ctx context.Context, key string) (string, error)
- func ResourceNameHasAtLeastOneOfPrefixes(resName string, prefixes ...string) bool
- func ToCoreResourceList(response *envoy_sd.DiscoveryResponse) (model.ResourceList, error)
- func ToEnvoyResources(rlist model.ResourceList) ([]envoy_types.Resource, error)
- func TrimSuffixFromName(r model.Resource, suffix string)
- func ZoneTag(r model.Resource) string
- type CloneResourceMetaOpt
- type NameToVersion
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddPrefixToNames ¶
func AddPrefixToResourceKeyNames ¶
func AddPrefixToResourceKeyNames(rk []model.ResourceKey, prefix string) []model.ResourceKey
func AddSuffixToNames ¶
func AddSuffixToResourceKeyNames ¶
func AddSuffixToResourceKeyNames(rk []model.ResourceKey, suffix string) []model.ResourceKey
func ClientIDFromIncomingCtx ¶
ClientIDFromIncomingCtx returns the ID of the peer. Global has the ID "global" while zones have the zone name. This is also known as the peer ID.
func CloneResourceMeta ¶
func CloneResourceMeta(m model.ResourceMeta, fs ...CloneResourceMetaOpt) model.ResourceMeta
func DubboResourceMetaToResourceMeta ¶
func DubboResourceMetaToResourceMeta(meta *mesh_proto.DubboResource_Meta) model.ResourceMeta
func GetSupportedTypes ¶
func GetSupportedTypes() []string
func MetadataFromIncomingCtx ¶
func ToCoreResourceList ¶
func ToCoreResourceList(response *envoy_sd.DiscoveryResponse) (model.ResourceList, error)
func ToEnvoyResources ¶
func ToEnvoyResources(rlist model.ResourceList) ([]envoy_types.Resource, error)
func TrimSuffixFromName ¶
TrimSuffixFromName is responsible for removing provided suffix with preceding dot from the name of provided model.Resource.
Types ¶
type CloneResourceMetaOpt ¶
type CloneResourceMetaOpt func(*resourceMeta)
func WithLabel ¶
func WithLabel(key, value string) CloneResourceMetaOpt
func WithName ¶
func WithName(name string) CloneResourceMetaOpt
type NameToVersion ¶
func ToDeltaCoreResourceList ¶
func ToDeltaCoreResourceList(response *envoy_sd.DeltaDiscoveryResponse) (model.ResourceList, NameToVersion, error)
Click to show internal directories.
Click to hide internal directories.