Skip to content
This repository was archived by the owner on Nov 9, 2017. It is now read-only.
This repository was archived by the owner on Nov 9, 2017. It is now read-only.

A way to check for existence of an index or river? #27

Description

@victor73

Is there a way to check for the existence of a particular index? I found the indexExists() method, however it doesn't seem to be documented or to work as expected. An index name that definitely exists according to the output of a curl call to /_status and /index_name/_status seems to return false when passed to indexExists():

client.indexExists(indexName, function(err, exists) {
    if (err) {
        throw err;
    }

    if (exists) {
        console.log("Exists");
    } else {
        console.log("Doesn't exist");
    }
}); 

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions