Documentation ¶
Index ¶
- Variables
- func BuildDataCenterMetadata(dataCenters []string, upstreams []*v1.Upstream) map[string]string
- func BuildTagMetadata(tags []string, upstreams []*v1.Upstream) map[string]string
- func NewPlugin(client consul.ConsulWatcher, resolver DnsResolver, ...) *plugin
- type ConsulDnsResolver
- type DnsResolver
Constants ¶
This section is empty.
Variables ¶
View Source
var ( DefaultDnsAddress = "127.0.0.1:8600" DefaultDnsPollingInterval = 5 * time.Second DefaultTlsTagName = "glooUseTls" UnformattedErrorMsg = "Consul settings specify automatic detection of TLS services, " + "but the rootCA resource's name/namespace are not properly specified: {%s}" ConsulTlsInputError = func(nsString string) error { return eris.Errorf(UnformattedErrorMsg, nsString) } )
Functions ¶
func BuildDataCenterMetadata ¶ added in v0.17.4
Similarly to what we do with tags, create a label for each data center and set it to "1" if the service instance is running in that data center.
func BuildTagMetadata ¶ added in v0.17.4
The ServiceTags on the Consul Upstream(s) represent all tags for Consul services with the given ServiceName across data centers. We create an endpoint label for each tag from the gloo upstreams, where the label key is the name of the tag and the label value is "1" if the current service contains the same tag, and "0" otherwise.
func NewPlugin ¶
func NewPlugin(client consul.ConsulWatcher, resolver DnsResolver, dnsPollingInterval *time.Duration) *plugin
Types ¶
type ConsulDnsResolver ¶ added in v1.3.7
type ConsulDnsResolver struct {
DnsAddress string
}
Click to show internal directories.
Click to hide internal directories.