public boolean doesResourceExist(final String resourcePath) throws IOException {
        Response response = elasticSearchAdminClient.performRequest(HttpMethod.HEAD, resourcePath);
        return response.getStatusLine().getStatusCode() == HttpStatus.SC_OK;
    }
Determines whether a resource exists in ES. This will call a GET method to a particular path
and return true if status 200; false otherwise.

@param resourcePath The path of the resource to get.
@return True if it exists; false otherwise.
@throws IOException If an error occurred during requests to ES.
es6-persistence/src/main/java/com/netflix/conductor/es6/dao/index/ElasticSearchRestDAOV6.java