consumeDelay
property might help; but it will slow down initialization because the delay is applied unconditionally between consuming from each queue. It will mean, for your last instance, it will be delayed 20x the delay./**
* Set the consumeDelay - a time to wait before consuming in ms. This is useful when
* using the sharding plugin with {@code concurrency > 1}, to avoid uneven distribution of
* consumers across the shards. See the plugin README for more information.
* @param consumeDelay the consume delay.
* @since 2.3
*/
public void setConsumeDelay(long consumeDelay) {
this.consumeDelay = consumeDelay;
}
!! External Email
|
!! External Email: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender.
|
consumeDelay
and give each instance the queue names in a different order (each one having a different queue as the first), then make sure the instances are all started within the
consumeDelay
.