Class KubernetesServiceInstanceServiceInformerProvider
java.lang.Object
io.micronaut.kubernetes.discovery.AbstractKubernetesServiceInstanceProvider
io.micronaut.kubernetes.discovery.provider.AbstractV1ServiceProvider
io.micronaut.kubernetes.discovery.provider.KubernetesServiceInstanceServiceInformerProvider
- All Implemented Interfaces:
KubernetesServiceInstanceProvider
@Requires(property="kubernetes.client.discovery.mode-configuration.service.watch.enabled",
notEquals="false",
defaultValue="false")
@Singleton
public class KubernetesServiceInstanceServiceInformerProvider
extends AbstractV1ServiceProvider
Service instance provider uses Kubernetes Service Informer as source of service discovery.
- Since:
- 3.2
- Author:
- Pavol Gressa
-
Nested Class Summary
Nested classes/interfaces inherited from class io.micronaut.kubernetes.discovery.AbstractKubernetesServiceInstanceProvider
AbstractKubernetesServiceInstanceProvider.PortBinder
-
Field Summary
Modifier and TypeFieldDescriptionprotected static final org.slf4j.Logger
protected static final String
Fields inherited from class io.micronaut.kubernetes.discovery.provider.AbstractV1ServiceProvider
EXTERNAL_NAME, MODE
Fields inherited from class io.micronaut.kubernetes.discovery.AbstractKubernetesServiceInstanceProvider
SECURE_LABEL
-
Constructor Summary
ConstructorDescriptionKubernetesServiceInstanceServiceInformerProvider
(KubernetesConfiguration.KubernetesDiscoveryConfiguration discoveryConfiguration, InstanceProviderInformerNamespaceResolver informerNamespaceResolver, IndexerCompositeFactory indexerCompositeFactory) Creates kubernetes instance endpoint provider. -
Method Summary
Modifier and TypeMethodDescriptionreactor.core.publisher.Mono<io.kubernetes.client.openapi.models.V1Service>
getService
(String name, String namespace) reactor.core.publisher.Flux<io.kubernetes.client.openapi.models.V1Service>
listServices
(String namespace) Methods inherited from class io.micronaut.kubernetes.discovery.provider.AbstractV1ServiceProvider
getInstances, getMode, getServiceIds
Methods inherited from class io.micronaut.kubernetes.discovery.AbstractKubernetesServiceInstanceProvider
buildServiceInstance, compositePredicate, discoveryConfigurationFilter, hasValidPortConfiguration, isMetadataSecure, isPortSecure, serviceConfigurationDiscoveryFilter
-
Field Details
-
RESOURCE_PLURAL
- See Also:
-
LOG
protected static final org.slf4j.Logger LOG
-
-
Constructor Details
-
KubernetesServiceInstanceServiceInformerProvider
public KubernetesServiceInstanceServiceInformerProvider(KubernetesConfiguration.KubernetesDiscoveryConfiguration discoveryConfiguration, InstanceProviderInformerNamespaceResolver informerNamespaceResolver, IndexerCompositeFactory indexerCompositeFactory) Creates kubernetes instance endpoint provider.- Parameters:
discoveryConfiguration
- discovery configurationindexerCompositeFactory
- service instance provider informer factoryinformerNamespaceResolver
- namespace resolver
-
-
Method Details
-
getService
public reactor.core.publisher.Mono<io.kubernetes.client.openapi.models.V1Service> getService(String name, String namespace) - Specified by:
getService
in classAbstractV1ServiceProvider
-
listServices
public reactor.core.publisher.Flux<io.kubernetes.client.openapi.models.V1Service> listServices(String namespace) - Specified by:
listServices
in classAbstractV1ServiceProvider
-