@Override
  public Client getClient() {
    Settings settings = Settings.settingsBuilder()
        .put(clientSettings)
        .build();

    Node node = NodeBuilder.nodeBuilder()
        .client(true)
        .settings(settings)
        .build();

    return node.client();
  }
A {@link ClientFactory} that creates a {@link Node} client that connects to
and joins an Elasticsearch cluster.

<p>
How the Node discovers and joins the cluster can be configured
via Elasticsearch settings in the properties of the Samza job.
</p>
samza-elasticsearch/src/main/java/org/apache/samza/system/elasticsearch/client/NodeClientFactory.java