Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display ES version as part of index.version in index settings #17862

Closed
ppf2 opened this issue Apr 19, 2016 · 3 comments
Closed

Display ES version as part of index.version in index settings #17862

ppf2 opened this issue Apr 19, 2016 · 3 comments
Labels
:Core/Infra/REST API REST infrastructure and utilities :Data Management/Stats Statistics tracking and retrieval APIs discuss >enhancement

Comments

@ppf2
Copy link
Member

ppf2 commented Apr 19, 2016

Describe the feature:

Currently, we display index.version.created in index settings as Lucene version string, eg. 1070199.

For most end users out/admins there, this is often not intuitive unless they know to check the mapping here.

    "settings" : {
      "index" : {
        "creation_date" : "1460617724303",
        "number_of_shards" : "5",
        "number_of_replicas" : "1",
        "version" : {
          "created" : "1070199"
        }
      }
    }

The index.version.created has become more useful as we make changes to the product. For example, with the fielddata to doc_values change, it is helpful to look at the index created version to determine if the index was created on 1.7 (which defaults to fielddata). Looking at the mappings api output will not provide this information anymore on 2.x because all fields default to doc values (so if a mapped field has no doc_values setting showing from the mappings api, is it using doc values on 2.x? Or really using fielddata because the index was created on 1.x). A quick way to check will be to look at the index.version.created field. In 5.0, I believe we also have some internal data-structures that do not get upgraded as part of the regular merge process (or upgrade api) and requires creating the index on 5.0. So having the index.version.created be a string that is intuitive to the end user will be helpful.

For example, can we show it as V_1_7_1 (1070199) instead of just 1070199? Or add another field under index.version showing the corresponding V_1_7_1 (if changing the format of index.version.created will break backwards compatibility).

@clintongormley clintongormley added discuss :Core/Infra/REST API REST infrastructure and utilities :Data Management/Stats Statistics tracking and retrieval APIs labels Apr 20, 2016
@girirajsharma
Copy link
Contributor

Human readable format already does that, isn't ?

curl -XGET http://localhost:9200/{index_name}/_settings/?pretty

"settings": {
    "index": {
      "creation_date": "1461220754753",
      "number_of_shards": "5",
      "number_of_replicas": "1",
      "uuid": "drUys0-HSdGSyw5iuJeOzg",
      "version": {
        "created": "5000099"
      }
    }
  }

curl -XGET http://localhost:9200/{index_name}/_settings/?pretty&human

"settings": {
    "index": {
      "creation_date_string": "2016-04-21T06:39:14.753Z",
      "number_of_shards": "5",
      "creation_date": "1461220754753",
      "number_of_replicas": "1",
      "uuid": "drUys0-HSdGSyw5iuJeOzg",
      "version": {
        "created_string": "5.0.0",
        "created": "5000099"
      }
    }
  }

@jasontedor
Copy link
Member

Human readable format already does that, isn't ?

Yes, it does. Thank you.

@ppf2
Copy link
Member Author

ppf2 commented Apr 21, 2016

Nice! Didn't realize we already do this via the human parameter, would be nice for it to be the default, but this is certainly sufficient. thx!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Core/Infra/REST API REST infrastructure and utilities :Data Management/Stats Statistics tracking and retrieval APIs discuss >enhancement
Projects
None yet
Development

No branches or pull requests

4 participants