/** * {@inheritdoc} */ public function findByLabels(array $labels) { $labelSelector = HttpAdapter::createLabelSelector($labels); $url = $this->namespaceClient->prefixPath('/ingresses?labelSelector=' . $labelSelector); $url = '/apis/extensions/v1beta1' . $url; return $this->connector->get($url, ['class' => IngressList::class]); }
/** * {@inheritdoc} */ public function findByReplicationController(ReplicationController $replicationController) { $selector = $replicationController->getSpecification()->getSelector(); $labelSelector = HttpAdapter::createLabelSelector($selector); $path = '/pods?labelSelector=' . urlencode($labelSelector); return $this->connector->get($this->namespaceClient->prefixPath($path), ['class' => PodList::class, 'groups' => ['Default', 'show']]); }
/** * {@inheritdoc} */ public function findByLabels(array $labels) { $labelSelector = HttpAdapter::createLabelSelector($labels); $url = $this->namespaceClient->prefixPath('/services?labelSelector=' . $labelSelector); return $this->connector->get($url, ['class' => ServiceList::class]); }
/** * {@inheritdoc} */ public function findByLabels(KeyValueObjectList $labels) { return $this->connector->get('/namespaces?' . http_build_query(['labelSelector' => HttpAdapter::createLabelSelector($labels->toAssociativeArray())]), ['class' => NamespaceList::class]); }
/** * {@inheritdoc} */ public function findByLabels(array $labels) { $labelSelector = HttpAdapter::createLabelSelector($labels); $path = $this->namespaceClient->prefixPath('/replicationcontrollers?labelSelector=' . $labelSelector); /** @var ReplicationControllerList $found */ $found = $this->connector->get($path, ['class' => ReplicationControllerList::class]); return $found; }