Class DefaultEndpointLocator

java.lang.Object
org.springframework.cloud.sleuth.zipkin2.DefaultEndpointLocator
All Implemented Interfaces:
EventListener, EndpointLocator, org.springframework.context.ApplicationListener<org.springframework.boot.web.servlet.context.ServletWebServerInitializedEvent>

public class DefaultEndpointLocator extends Object implements EndpointLocator, org.springframework.context.ApplicationListener<org.springframework.boot.web.servlet.context.ServletWebServerInitializedEvent>
EndpointLocator implementation that. serviceName - from ServerProperties or Registration ip - from ServerProperties port - from lazily assigned port or ServerProperties You can override the name using ZipkinProperties.Service.setName(String)
Since:
3.0.0
Author:
Dave Syer
  • Constructor Summary

    Constructors
    Constructor
    Description
    DefaultEndpointLocator(org.springframework.cloud.client.serviceregistry.Registration registration, org.springframework.boot.autoconfigure.web.ServerProperties serverProperties, org.springframework.core.env.Environment environment, ZipkinProperties zipkinProperties, org.springframework.cloud.commons.util.InetUtils inetUtils)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    zipkin2.Endpoint
     
    void
    onApplicationEvent(org.springframework.boot.web.servlet.context.ServletWebServerInitializedEvent event)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • DefaultEndpointLocator

      public DefaultEndpointLocator(org.springframework.cloud.client.serviceregistry.Registration registration, org.springframework.boot.autoconfigure.web.ServerProperties serverProperties, org.springframework.core.env.Environment environment, ZipkinProperties zipkinProperties, org.springframework.cloud.commons.util.InetUtils inetUtils)
  • Method Details

    • local

      public zipkin2.Endpoint local()
      Specified by:
      local in interface EndpointLocator
    • onApplicationEvent

      public void onApplicationEvent(org.springframework.boot.web.servlet.context.ServletWebServerInitializedEvent event)
      Specified by:
      onApplicationEvent in interface org.springframework.context.ApplicationListener<org.springframework.boot.web.servlet.context.ServletWebServerInitializedEvent>