-
Notifications
You must be signed in to change notification settings - Fork 25.7k
Closed
Labels
:Data Management/Indices APIsAPIs to create and manage indices and templatesAPIs to create and manage indices and templates>buggood first issuelow hanging fruitlow hanging fruit
Description
Elasticsearch version:
5.2.2
Plugins installed: []
head
JVM version:
java version "1.8.0_121"
Java(TM) SE Runtime Environment (build 1.8.0_121-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.121-b13, mixed mode)
OS version:
Linux 3.10.0-229.el7.x86_64
Description of the problem including expected versus actual behavior:
With two index named foo_foo and bar_bar with the same alias foo like below:
| index | alias |
|---|---|
| foo_foo | foo |
| bar_bar | foo |
If use the following to remove the alias, only the alias of 'foo_foo' is removed, that's fine.
POST /_aliases
{
"actions": [
{
"remove": {
"index": "foo_*",
"alias": "foo"
}
}
]
}
BUT, if use the following to remove, both the alias of foo_foo and bar_bar will be removed, while I think only the foo_foo 's alias should be removed
POST /_aliases
{
"actions": [
{
"remove": {
"index": "foo*",
"alias": "foo"
}
}
]
}
Steps to reproduce:
- Create Two Index using the following:
PUT /foo_foo
PUT /bar_bar
- Add Alias for them using:
POST /_aliases
{
"actions" : [
{ "add" : { "index" : "foo_foo", "alias" : "foo" } },
{ "add" : { "index" : "bar_bar", "alias" : "foo" } }
]
}
- delete alias using:
POST /_aliases
{
"actions": [
{
"remove": {
"index": "foo_*",
"alias": "foo"
}
}
]
}
Metadata
Metadata
Assignees
Labels
:Data Management/Indices APIsAPIs to create and manage indices and templatesAPIs to create and manage indices and templates>buggood first issuelow hanging fruitlow hanging fruit