Documentation ¶
Index ¶
- func GetServiceEvents(client client.Interface, dsQuery *dataselect.DataSelectQuery, ...) (*common.EventList, error)
- func GetServicePods(client k8sClient.Interface, metricClient metricapi.MetricClient, ...) (*pod.PodList, error)
- type Service
- type ServiceCell
- type ServiceDetail
- type ServiceList
- func CreateServiceList(services []v1.Service, nonCriticalErrors []error, ...) *ServiceList
- func GetServiceList(client client.Interface, nsQuery *common.NamespaceQuery, ...) (*ServiceList, error)
- func GetServiceListFromChannels(channels *common.ResourceChannels, dsQuery *dataselect.DataSelectQuery) (*ServiceList, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetServiceEvents ¶ added in v1.6.3
func GetServiceEvents(client client.Interface, dsQuery *dataselect.DataSelectQuery, namespace, name string) ( *common.EventList, error)
GetServiceEvents returns model events for a service with the given name in the given namespace.
func GetServicePods ¶
func GetServicePods(client k8sClient.Interface, metricClient metricapi.MetricClient, namespace, name string, dsQuery *dataselect.DataSelectQuery) (*pod.PodList, error)
GetServicePods gets list of pods targeted by given label selector in given namespace.
Types ¶
type Service ¶
type Service struct { ObjectMeta api.ObjectMeta `json:"objectMeta"` TypeMeta api.TypeMeta `json:"typeMeta"` // InternalEndpoint of all Kubernetes services that have the same label selector as connected Replication // Controller. Endpoint is DNS name merged with ports. InternalEndpoint common.Endpoint `json:"internalEndpoint"` // ExternalEndpoints of all Kubernetes services that have the same label selector as connected Replication // Controller. Endpoint is external IP address name merged with ports. ExternalEndpoints []common.Endpoint `json:"externalEndpoints"` // Label selector of the service. Selector map[string]string `json:"selector"` // Type determines how the service will be exposed. Valid options: ClusterIP, NodePort, LoadBalancer Type v1.ServiceType `json:"type"` // ClusterIP is usually assigned by the master. Valid values are None, empty string (""), or // a valid IP address. None can be specified for headless services when proxying is not required ClusterIP string `json:"clusterIP"` }
Service is a representation of a service.
type ServiceCell ¶ added in v1.4.0
func (ServiceCell) GetProperty ¶ added in v1.4.0
func (self ServiceCell) GetProperty(name dataselect.PropertyName) dataselect.ComparableValue
type ServiceDetail ¶
type ServiceDetail struct { ObjectMeta api.ObjectMeta `json:"objectMeta"` TypeMeta api.TypeMeta `json:"typeMeta"` // InternalEndpoint of all Kubernetes services that have the same label selector as connected Replication // Controller. Endpoint is DNS name merged with ports. InternalEndpoint common.Endpoint `json:"internalEndpoint"` // ExternalEndpoints of all Kubernetes services that have the same label selector as connected Replication // Controller. Endpoint is external IP address name merged with ports. ExternalEndpoints []common.Endpoint `json:"externalEndpoints"` // Label selector of the service. Selector map[string]string `json:"selector"` // Type determines how the service will be exposed. Valid options: ClusterIP, NodePort, LoadBalancer Type v1.ServiceType `json:"type"` // ClusterIP is usually assigned by the master. Valid values are None, empty string (""), or // a valid IP address. None can be specified for headless services when proxying is not required ClusterIP string `json:"clusterIP"` // List of events related to this Service EventList common.EventList `json:"eventList"` // PodList represents list of pods targeted by same label selector as this service. PodList pod.PodList `json:"podList"` // List of non-critical errors, that occurred during resource retrieval. Errors []error `json:"errors"` }
Service is a representation of a service.
func GetServiceDetail ¶
func GetServiceDetail(client k8sClient.Interface, metricClient metricapi.MetricClient, namespace, name string, dsQuery *dataselect.DataSelectQuery) (*ServiceDetail, error)
GetServiceDetail gets service details.
func ToServiceDetail ¶
func ToServiceDetail(service *v1.Service) ServiceDetail
ToServiceDetail returns api service object based on kubernetes service object
type ServiceList ¶
type ServiceList struct { ListMeta api.ListMeta `json:"listMeta"` // Unordered list of services. Services []Service `json:"services"` // List of non-critical errors, that occurred during resource retrieval. Errors []error `json:"errors"` }
ServiceList contains a list of services in the cluster.
func CreateServiceList ¶
func CreateServiceList(services []v1.Service, nonCriticalErrors []error, dsQuery *dataselect.DataSelectQuery) *ServiceList
CreateServiceList returns paginated service list based on given service array and pagination query.
func GetServiceList ¶
func GetServiceList(client client.Interface, nsQuery *common.NamespaceQuery, dsQuery *dataselect.DataSelectQuery) (*ServiceList, error)
GetServiceList returns a list of all services in the cluster.
func GetServiceListFromChannels ¶
func GetServiceListFromChannels(channels *common.ResourceChannels, dsQuery *dataselect.DataSelectQuery) (*ServiceList, error)
GetServiceListFromChannels returns a list of all services in the cluster.