Skip to content

Commit

Permalink
Renaming after review
Browse files Browse the repository at this point in the history
  • Loading branch information
UyumazHakan committed Oct 26, 2022
1 parent 86507f5 commit 9ca417d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions es.go
Original file line number Diff line number Diff line change
Expand Up @@ -1630,8 +1630,8 @@ type AllocateStalePrimary struct {
AcceptDataLoss bool `json:"accept_data_loss,omitempty"`
}

// Reroute allows to change the allocation of individual shards in the cluster.
func (c *Client) Reroute() error {
// RerouteWithRetryFailed retries allocation of shards that are blocked due to too many subsequent allocation failures.
func (c *Client) RerouteWithRetryFailed() error {
var urlBuilder strings.Builder
urlBuilder.WriteString("_cluster/reroute?retry_failed=true")

Expand Down
2 changes: 1 addition & 1 deletion es_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2190,7 +2190,7 @@ func TestReroute(t *testing.T) {
defer ts.Close()
client := NewClient(host, port)

err := client.Reroute()
err := client.RerouteWithRetryFailed()
if err != nil {
t.Fatalf("Unexpected error expected nil, got %s", err)
}
Expand Down

0 comments on commit 9ca417d

Please sign in to comment.