Add and remove alias timeout

es : 5.6.3 1 master and 4 datanode

OS : centos 6.9 x86_64

JAVA : java version "1.8.0_66"
Java(TM) SE Runtime Environment (build 1.8.0_66-b17)
Java HotSpot(TM) 64-Bit Server VM (build 25.66-b17, mixed mode)

request rate: query per second 2k/s

Steps:

1, create inde user-20180701
2, loaddata to user-20180701
3, sleep 30 and flush
4, curl -s -H "Content-Type:application/json; charset=UTF-8" -X POST 'http://localhost:9200/_aliases' -d '{"actions":[{"add":{"index":"user-20180701","alias":"userdata"}}]}'
5, curl -s -H "Content-Type:application/json; charset=UTF-8" -X POST 'http://localhost:9200/_aliases' -d '{"remove":[{"add":{"index":"user-20180631","alias":"userdata"}}]}'

Steps 4 , 10% - 20% request timeout

Why have you split the alias update into two steps? It's both safer and faster to make it an atomic operation (see Index Aliases), e.g.

curl -X POST "localhost:9200/_aliases" -H 'Content-Type: application/json' -d'
{
    "actions" : [
        { "remove" : { "index" : "user-20180631", "alias" : "userdata" } },
        { "add" :    { "index" : "user-20180701", "alias" : "userdata" } }
    ]
}
'

a transaction 。 Same as before。

up up

What is the load on your cluster? How many indices and shards do you have?

cluster load (1)loaddata > (2) add and remove alias

but loaddata no timetout

1 master and 4 datanode ( 1 datanode : 8 ssd . 16vcpu ,64G ram ).

24 shard , 1 rep.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.