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

Make index required in DELETE index API #4481

Closed
clintongormley opened this issue Dec 17, 2013 · 5 comments
Closed

Make index required in DELETE index API #4481

clintongormley opened this issue Dec 17, 2013 · 5 comments

Comments

@clintongormley
Copy link

Currently this request:

DELETE /

... will delete all indices. We should change this to require an index name or wildcard, to prevent data loss from typos.

The delete-all syntax would be either of:

DELETE /_all
DELETE /*
@nik9000
Copy link
Member

nik9000 commented Dec 17, 2013

+1 for either syntax. Doesn't the /_all syntax match the close api? I'm going from memory here.

@clintongormley
Copy link
Author

It does, but you can also use /* wildcards for delete. We will be adding wildcards for open/close too.

@kwloafman
Copy link

As one who has learned painfully from that typo, I +1 this idea.

On Tue, Dec 17, 2013 at 8:59 AM, Clinton Gormley
notifications@github.comwrote:

It does, but you can also use /* wildcards for delete. We will be adding
wildcards for open/close too.


Reply to this email directly or view it on GitHubhttps://github.com//issues/4481#issuecomment-30757284
.

@javanna
Copy link
Member

javanna commented Jan 6, 2014

This issue will be incorporated in #4549, which consists of disallowing all destructive operations by default. The idea is to keep the DELETE / syntax around as it makes sense REST-wise, but will need to be enabled through a configuration parameter, that will work cross-APIs for all the potentially desctructive operations.

@javanna
Copy link
Member

javanna commented Jan 7, 2014

Update: the DELETE / won't be kept around in the end, but will be removed as it's harmful. Ignore my last comment.

martijnvg added a commit to martijnvg/elasticsearch that referenced this issue Jan 9, 2014
…rd expressions and `_all` is allowed to be used for destructive operat

Also the delete index api requires always an index to be specified (either concrete index, alias or wildcard expression)

Closes elastic#4549 elastic#4481
martijnvg added a commit that referenced this issue Jan 9, 2014
…rd expressions and `_all` is allowed to be used for destructive operat Also the delete index api requires always an index to be specified (either concrete index, alias or wildcard expression)

Closes #4549 #4481
brusic pushed a commit to brusic/elasticsearch that referenced this issue Jan 19, 2014
…rd expressions and `_all` is allowed to be used for destructive operat Also the delete index api requires always an index to be specified (either concrete index, alias or wildcard expression)

Closes elastic#4549 elastic#4481
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants