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

Update Settings API: Allow to dynamically change the number of replicas #302

Closed
kimchy opened this issue Aug 8, 2010 · 8 comments
Closed

Comments

@kimchy
Copy link
Member

kimchy commented Aug 8, 2010

A new API, update index / indices settings, allowing to change specific index level settings. The first setting supported is the index.number_of_replicas setting allowing to dynamically change the number of replicas an index has.

The REST endpoint is /_settings (to update all indices) or {index}/_settings to update one (or more) indices settings. The body of the request includes the updated settings, for example:

{
    "index" : {
        "number_of_replicas" : 4
    }
}

The above will change the number of replicas to 4 from the current number of replicas. Here is a curl example:

curl -XPUT 'localhost:9200/my_index/_settings' -d '
{
    "index" : {
        "number_of_replicas" : 4
    }
}
'
@kimchy
Copy link
Member Author

kimchy commented Aug 8, 2010

implements.

@otisg
Copy link

otisg commented Aug 9, 2010

Nice! So when the number of replicas is increased, what happens? e.g.

  • Does ES start copying indices from master node to additional nodes?
  • Does replication start immediately?
  • Can one throttle the replication speed? (because sudden network and disk IO will affect query throughput)
  • Can one reduce the number or replicas?
  • In case of replica reduction, do indices get physically removed from disk?

Thanks.

@kimchy
Copy link
Member Author

kimchy commented Aug 9, 2010

  • Indices are not copied from the master node, they are recovered from a primary shard that is allocated "somewhere" in the cluster.
  • Yes.
  • There is built in throttling to not perform recovery from / to many shards at the same time.
  • Yes.
  • Yes.

@clintongormley
Copy link

Btw, this isn't in the ES docs yet

@ayush21792
Copy link

Could you please tell how can we change index replica using java code???
I have done it through curl request but stuck while doing it through java code

@imotov
Copy link
Contributor

imotov commented Oct 31, 2014

@ayush21792 you can find plenty of examples of using java API in elasticsearch integration tests. Saying that, the best place to ask questions like these is elasticsearch mailing list. We are trying to use github issues to track bugs and feature requests.

@ayush21792
Copy link

Thank you so much....
Could you please help me on another issue..When I index very large data of
12.7 million records,my elastic search server is terminating after 8.3
million records and showing the error of java heap memory overflow and the
error persists even after increasing memory.I am using 2gb java heap memory
and have also tried for 1gb and 3gb but result is same(halting at 8.3
million records).I have tried with both java api and es server both are
giving the same result.I am using windows 7.So could u please help me if
there is any setting which i am ignoring.

Thank You

On Fri, Oct 31, 2014 at 5:14 PM, Igor Motov notifications@github.com
wrote:

@ayush21792 https://github.com/ayush21792 you can find plenty of
examples of using java API in elasticsearch integration tests
https://github.com/elasticsearch/elasticsearch/blob/master/src/test/java/org/elasticsearch/indices/settings/UpdateNumberOfReplicasTests.java#L75.
Saying that, the best place to ask questions like these is elasticsearch
mailing list. We are trying to use github issues to track bugs and feature
requests.


Reply to this email directly or view it on GitHub
#302 (comment)
.

@ayush21792
Copy link

Ayush Gupta would like to connect on LinkedIn. How would you like to respond?

Accept: https://www.linkedin.com/blink?simpleRedirect=0SejoPcjoTe3AVcP0PdP8UdzARfkh9rCZFt65QqnpKqioTmloRmk9fqjRVpkJApn9xq7cCej5vs7xBnTpKqjRHpipOpmhKqmRBsyRQs6lzoS4JoyRDtCVFnSRJrScJr6RBfmtKqmJzon9Q9ClQqnpKimtBkClOs3Rx9CoJrmFxpCYTdCAJu6hUsC9EbjRBfP9SbSkLrmZzbCVFp6lHrCBIbDtTtOYLeDdMt7hE&msgID=I5968273076624846849_500&markAsRead=

View Ayush Gupta's profile: https://www.linkedin.com/blink?simpleRedirect=ej5vs7xBnTpKqjRHpipOpmhKqmRBsyRQs6lzoS4JoyRDtCVFnSRJrScJr6RBfmtKqmJzon9Q9DpMrzRQ9CoJrmFxpCYTdCAJu6hUsC9EbjRBfP9SbSkLrmZzbCVFp6lHrCBIbDtTtOYLeDdMt7hE&msgID=I5968273076624846849_500&markAsRead=

You are receiving Reminder emails for pending invitations. Unsubscribe here: https://www.linkedin.com/blink?simpleRedirect=1JrSd5cylytmxQqmt5cylVr71Bsz0Q9j8ScjwOd3AJd38Qe6pzcjlApCdAojkVe3oNdj1Ae3sRojxxe6kOdjhzczdBe6oTciQMczcOdP8Jqk8O9nBIs6lOfmNFomRB9z0Sc30OfmhF9zoVdzcNdzsUejAPc3cTczwSejkZp6BD9zANnT1UplZSrCAZqSkCoDlPrDkJpyRzoClJnSRJrScJr6RBfmtKqmJzon9Q9CZLpPRQ9CoJrmFxpCYTdCAJu6hUsC9EbjRBfP9SbSkLrmZzbCVFp6lHrCBIbDtTtOYLeDdMt7hE&msgID=I5968273076624846849_500&markAsRead=

You received an invitation to connect. LinkedIn will use your email address to make suggestions to our members in features like People You May Know. Unsubscribe here: https://www.linkedin.com/blink?simpleRedirect=1CbmRGompLdPpFbnxAu79yq2QZp6BB9ztAi6sQejoQh71ydkkVdQJIjlBNoTcTgnBes5hds7pFqlFvlnx1gQhIe6wJm39KjzsPdngRpjxjgmpScllRiPBOpS8Sum8UjPlIukpUciReojdMoT1xjRFarll7tD5Jhm5zi7B9qBd5rmVeu7dHh3xek4lkmB9ejBhVsSMVk3xmiARzh4VorPtGozhUkDllgk51gmhbtmQPh6RqcjB8kk4Zp6BLr2oVclZMu6lvtCVFfmJB9B4ScSh5hSxmhD9JhB51fmVBqSZkp6BJ9CVRr3RQ9CoJrmFxpCYTdCAJu6hUsC9EbjRBfP9SbSkLrmZzbCVFp6lHrCBIbDtTtOYLeDdMt7hE&msgID=I5968273076624846849_500&markAsRead= Learn why we included this at the following link: https://www.linkedin.com/blink?simpleRedirect=0Ue3sQfmh9pmNzqnhOoioVclZMu6lvtCVFfmJB9CNOlmlzqnpOpldOpmRLt7dRoPRx9CoJrmFxpCYTdCAJu6hUsC9EbjRBfP9SbSkLrmZzbCVFp6lHrCBIbDtTtOYLeDdMt7hE&msgID=I5968273076624846849_500&markAsRead=
© 2014, LinkedIn Corporation. 2029 Stierlin Ct. Mountain View, CA 94043, USA

williamrandolph pushed a commit to williamrandolph/elasticsearch that referenced this issue Jun 4, 2020
mindw pushed a commit to mindw/elasticsearch that referenced this issue Sep 5, 2022
…quest elastic#302)

MPC-3388 terraform CNAMEs for sandboxes

* WIP for CNAME-ing

* wip, working fine despite being ugly

* working certificate creation for alb & cloudfront

* extract acm pieces from cloudfront.tf, validate multiple vars configurations

* create a naked ALB in shared-assets

* add rules per stack to said naked ALB

* update default redirect, fix redirect paths

* implementing reviewers suggested changes

* update naming as per review

* typing variables, fixing default values


Approved-by: Gideon Avida
Approved-by: Can Yildiz
costin pushed a commit that referenced this issue Dec 6, 2022
Adds support for reading double fields (until we have proper ValuesSource support). Also adds division to allow for more interesting benchmarking scenarios (in particular to compare with scripting).
emilykmarx pushed a commit to emilykmarx/elasticsearch that referenced this issue Dec 26, 2023
This issue was closed.
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

5 participants