23 Ağustos 2023 Çarşamba

Graceful Shutdown

Giriş
Şöyle tetiklenir
HazelcastInstance instance = ...;
instance.shutdown();
Açıklaması şöyle. Yani metod hemen sonlanmaz.
When you gracefully shutdown first node, shutdown process should wait (block) until data is safely backed up.
Açıklaması şöyle. MigrationManager devreye girer.
This means that it notifies master member, master member rebalances partitions, data are migrated off the shutting-down member, then it shuts down.
Açıklaması şöyle
When a member is being gracefully shut down, its partitions are migrated to other members. While partitions are migrating, the partition table still lists the shutting-down member as partition owner. So:
  • read only operations (e.g. map.get) are served normally by the shutting-down member
  • mutating operations (e.g. map.put but also others, including all EntryProcessor - related ops) fail with a PartitionMigratingException. This exception is retryable, so it is not immediately propagated to the user. Instead, internally Hazelcast retries for a certain count of retries (default is 250). If an invocation is retried for 100 times or more, then we log at WARNING level something like Retrying invocation: …, Reason: …
Once migrations are done, partition assignments table is updated and the partition invocation is retried on the new owner of the partition and should be executed successfully.
The operation will fail terminally (i.e. propagate an exception to the caller) if:
  • retry limit (default 250) is reached
  • operation call timeout is exceeded (not sure if this is 60 or 120 seconds)
That said, can you provide more details what is the expected behaviour and what is their observation?
MigrationListener İle İlişkisi
İşlem başlatılınca MigrationListener tetiklenir
Açıklaması şöyle
it only triggers when a node joins or leaves "gracefully", it doesn't trigger when a node leaves "ungracefully".

Hiç yorum yok:

Yorum Gönder

THIRD-PARTY.txt Dosyası

Kullanılan harici kütüphanelerin sürümleri bu dosyada Dosyanın yolu şöyle hazelcast/licenses/THIRD-PARTY.txt