How to delete document types in elasticsearch? -


i create index "myindex" specified document type "mytype". able delete index, appears "mytype" still exists without being tied index.

how rid of "mytype"?

if deleted index, mapping in index should not exist anymore. have other index in cluster similar type name?

to answer question: how delete document types in elasticsearch?, use delete mapping api:

curl -xdelete http://localhost:9200/index/type 

edit: elasticsearch 2.0, won't possible anymore. see mapping changes. have install delete query plugin , run query remove documents mapping still exist. better reindex documents in index without old type.

but @mguillemin , @javanna said, when delete index, every mapping attached index deleted well:

curl -xdelete http://localhost:9200/index 

Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -