code: public static URI getBaseUriForLocation(URI location) {
          // Any request to the public ELBs must be made over https
          boolean useHttps = location.getHost().toLowerCase().endsWith("nexus.bazaarvoice.com");
  
          return UriBuilder.fromUri(location)
                  .scheme(useHttps ? "https" : "http")
                  .replacePath(DataStoreClient.SERVICE_PATH)
                  .replaceQuery(null)
                  .build();
      }
docs: Returns the base URI for a location of type {@link LocationType#EMO_URL}.