I'm using Apache Ignite which is embedded in spring application(with tomcat) as a rest api server.
In my case, all node are server as data grid. and they serve specific data in memory. there is only one application each phisical server, and they are clustered by apache ignite.
but I have a probleam.
If I found a critical bug on that API, I need to fix and deploy.
So I have to deploy all application server. In that time, I should restart tomcat each server, then Rebalancing is occured. It makes worse performance to response during rebalancing, so sometimes My API will be not available.
My question is, should I always rebalance data whenever application is deployed?
If then, if the cluster is organized by thousands of nodes, should I go through thousands of rebalancing? Or Is there any other idea?
hope to your help, Thanks.
You can configure a time interval, during which rebalancing won't be triggered automatically. CacheConfiguration#rebalanceDelay parameter is responsible for it.
This way rebalancing won't be triggered right after the nodes leave. Data will need to be rebalanced to the restarted node only.
If you don't want any rebalancing to happen at all, you can configure native persistence and set a baseline topology. This way data will stay on nodes even after restart. And no data rebalancing will happen unless you change baseline topology manually. Note, that baseline topology feature is available since version 2.4. In previous versions you can use native persistence with rebalance delay instead.
Also some code changes may be performed without cluster restart, using deployment SPI. But currently only compute tasks can be updated this way.