elasticsearch
elasticsearch copied to clipboard
Handle scheduler shutdown in `MasterService`
Today if ThreadPool#scheduler
is shut down while submitting a task for
execution by the MasterService
then we directly throw the rejection
exception to the caller. By the looks of it most callers don't expect
this method to throw anything, so this commit adjusts the behaviour to
fail the task instead.
Closes #105549
Pinging @elastic/es-distributed (Team:Distributed)