code: static String clientNameForHost(String host) {
      Matcher m = PREFIX.matcher(host);
      return m.matches() ? m.group(1) : DEFAULT;
    }
docs: Extract a client name based on the host. This will currently select up
  to the first dash or dot in the name. The goal is to have a reasonable
  name, but avoid a large explosion in number of names in dynamic environments
  such as EC2. Examples:
  
  <pre>
  name      host
  ----------------------------------------------------
  foo       foo.test.netflix.com
  ec2       ec2-127-0-0-1.compute-1.amazonaws.com
  </pre>