Class EurekaServiceInstanceList

java.lang.Object
io.micronaut.discovery.client.DiscoveryServerInstanceList
io.micronaut.discovery.eureka.EurekaServiceInstanceList
All Implemented Interfaces:
io.micronaut.context.event.ApplicationEventListener<io.micronaut.runtime.server.event.ServerStartupEvent>, io.micronaut.core.order.Ordered, io.micronaut.discovery.ServiceInstanceList, EventListener

@Singleton @RequiresEureka public class EurekaServiceInstanceList extends DiscoveryServerInstanceList

A ServiceInstanceList for Consul which reads from the EurekaConfiguration.

The reason this is useful is if a RefreshEvent occurs then the EurekaConfiguration will be updated and the backing list of ServiceInstance changed at runtime.

Since:
1.0
Author:
Graeme Rocher
  • Constructor Details

    • EurekaServiceInstanceList

      @Inject public EurekaServiceInstanceList(EurekaConfiguration configuration, io.micronaut.runtime.ApplicationConfiguration.InstanceConfiguration instanceConfiguration)
      Creates a new eureka service instance list.
      Parameters:
      configuration - The discovery config
      instanceConfiguration - The instance config
  • Method Details

    • getID

      public String getID()