service

package
v1.7.0-alpha.4 Latest Latest
Warning

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

Go to latest
Published: May 18, 2017 License: Apache-2.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DNSControllerName = "service-dns"

	DNSUserAgentName = "federation-service-dns-controller"
)
View Source
const (
	UserAgentName = "federation-service-controller"

	ControllerName = "services"
)
View Source
const (
	FederatedServiceIngressAnnotation = "federation.kubernetes.io/service-ingresses"
)

Variables

View Source
var (
	RequiredResources = []schema.GroupVersionResource{v1.SchemeGroupVersion.WithResource("services")}
)

Functions

func Equivalent added in v1.7.0

func Equivalent(s1, s2 *v1.Service) bool

Equivalent Checks if cluster-independent, user provided data in two given services are equal. If in the future the services structure is expanded then any field that is not populated by the api server should be included here.

func UpdateIngressAnnotation

func UpdateIngressAnnotation(service *v1.Service, ingress *FederatedServiceIngress) *v1.Service

UpdateIngressAnnotation updates the federated service with service ingress annotation

Types

type FederatedServiceIngress

type FederatedServiceIngress struct {
	fedapi.FederatedServiceIngress
}

FederatedServiceIngress implements sort.Interface.

func NewFederatedServiceIngress

func NewFederatedServiceIngress() *FederatedServiceIngress

func ParseFederatedServiceIngress

func ParseFederatedServiceIngress(service *v1.Service) (*FederatedServiceIngress, error)

ParseFederatedServiceIngress extracts federated service ingresses from a federated service

func (*FederatedServiceIngress) AddClusterLoadBalancerIngresses

func (ingress *FederatedServiceIngress) AddClusterLoadBalancerIngresses(cluster string, loadbalancerIngresses []v1.LoadBalancerIngress)

AddClusterLoadBalancerIngresses adds the ladbalancer ingresses for a given cluster to federated service ingress

func (*FederatedServiceIngress) AddEndpoints

func (ingress *FederatedServiceIngress) AddEndpoints(cluster string, endpoints []string) *FederatedServiceIngress

AddEndpoints add one or more endpoints to federated service ingress. endpoints are federated cluster's loadbalancer ip/hostname for the service

func (*FederatedServiceIngress) GetClusterLoadBalancerIngresses

func (ingress *FederatedServiceIngress) GetClusterLoadBalancerIngresses(cluster string) []v1.LoadBalancerIngress

GetClusterLoadBalancerIngresses returns loadbalancer ingresses for given cluster if exist otherwise returns an empty slice

func (*FederatedServiceIngress) Len

func (ingress *FederatedServiceIngress) Len() int

Len is to satisfy of sort.Interface.

func (*FederatedServiceIngress) Less

func (ingress *FederatedServiceIngress) Less(i, j int) bool

Less is to satisfy of sort.Interface.

func (*FederatedServiceIngress) RemoveEndpoint

func (ingress *FederatedServiceIngress) RemoveEndpoint(cluster string, endpoint string) *FederatedServiceIngress

RemoveEndpoint removes a single endpoint (ip/hostname) from the federated service ingress

func (*FederatedServiceIngress) String

func (ingress *FederatedServiceIngress) String() string

func (*FederatedServiceIngress) Swap

func (ingress *FederatedServiceIngress) Swap(i, j int)

Swap is to satisfy of sort.Interface.

type ServiceController

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

func New

func New(federationClient fedclientset.Interface) *ServiceController

New returns a new service controller to keep DNS provider service resources (like Kubernetes Services and DNS server records for service discovery) in sync with the registry.

func (*ServiceController) Run

func (s *ServiceController) Run(workers int, stopCh <-chan struct{})

It's an error to call Run() more than once for a given ServiceController object.

type ServiceDNSController

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

func NewServiceDNSController

func NewServiceDNSController(client fedclientset.Interface, dnsProvider, dnsProviderConfig, federationName,
	serviceDNSSuffix, zoneName, zoneID string) (*ServiceDNSController, error)

NewServiceDNSController returns a new service dns controller to manage DNS records for federated services

func (*ServiceDNSController) DNSControllerRun

func (s *ServiceDNSController) DNSControllerRun(workers int, stopCh <-chan struct{})

Jump to

Keyboard shortcuts

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