private String getLocalNodeId(String name) {
   Discovery discovery = internalCluster().getInstance(Discovery.class, name);
   String nodeId = discovery.localNode().getId();
   assertThat(nodeId, not(nullValue()));
   return nodeId;
 }