forked from linkedin/venice
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[server][controller] Try ungraceful close when the graceful one faile… (
linkedin#828) * [server][controller] Try ungraceful close when the graceful one failed in VeniceWriter In VeniceWriter.close(), when gracefulClose is set to true, Kafka producer call the underlining method, which tries to flush the buffered data before closing it (see ApacheKafkaProducerAdapter.close). However, when exception happens (e.g. timeout), today, VeniveWriter only logs the exception, moves on, and consider the VeniceWriter being closed while it is actually not. (A leaking venicewriter can cause several issues, e.g. a stuck consumer thread etc.) This change adds a retry of ungraceful close if gracefulClose flag is set to true and it failed. In this case, ungraceful close will skip the flushing step and it should always succeed (e.g. StoreIngestionTask.kill()). For cases where gracefulClose is set to false, this change doesn't change anything.
- Loading branch information
Showing
4 changed files
with
211 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters