java.lang.Object
com.microservices.starter.core.environment.Domain
All Implemented Interfaces:
Serializable

public class Domain extends Object implements Serializable
Domain (DNS) information used at runtime for dynamic application configuration to negotiate gateway routing and interservice communication appropriately based on the deployed environment. Required.
See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected boolean
     
    boolean
     
    Alternate domain names by which this component may be known.
    The domain to use when the service is called from inside of a cloud environment (e.g.
    The domain to use when the service is called from inside of docker by another component in docker.
    The domain to use when calling the service from a local context (e.g.
    int
     
    void
    setAlternates(List<String> alternates)
    Alternate domain names by which this component may be known.
    void
    The domain to use when the service is called from inside of a cloud environment (e.g.
    void
    setDocker(String docker)
    The domain to use when the service is called from inside of docker by another component in docker.
    void
    The domain to use when calling the service from a local context (e.g.
     

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • Domain

      public Domain()
  • Method Details

    • getLocal

      public String getLocal()
      The domain to use when calling the service from a local context (e.g. localhost)
    • getDocker

      public String getDocker()
      The domain to use when the service is called from inside of docker by another component in docker.
    • getCloud

      public String getCloud()
      The domain to use when the service is called from inside of a cloud environment (e.g. k8s) by another component in that environment.
    • getAlternates

      public List<String> getAlternates()
      Alternate domain names by which this component may be known. This primarily serves to inform the SAN value on one or more https keystore certs so that trust can be properly established regardless of environment. Since the SAN value is set at cert creation during initial project construction, it is useful to set all the possible values here, so they are available at inception. This should include domain overrides that may be set in other environments at runtime (via environment variable).
    • setLocal

      public void setLocal(String local)
      The domain to use when calling the service from a local context (e.g. localhost)
    • setDocker

      public void setDocker(String docker)
      The domain to use when the service is called from inside of docker by another component in docker.
    • setCloud

      public void setCloud(String cloud)
      The domain to use when the service is called from inside of a cloud environment (e.g. k8s) by another component in that environment.
    • setAlternates

      public void setAlternates(List<String> alternates)
      Alternate domain names by which this component may be known. This primarily serves to inform the SAN value on one or more https keystore certs so that trust can be properly established regardless of environment. Since the SAN value is set at cert creation during initial project construction, it is useful to set all the possible values here, so they are available at inception. This should include domain overrides that may be set in other environments at runtime (via environment variable).
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object