We just had a situation in which there was no path to our elastic search server. Admincp could not even be opened to turn off elastic search because it tries to connect to elastic search. In the end I tried to disable the option directly via database which also did not work (cached, I guess.) I had to change the hosts on our servers to force the attempted elastic search connections to immediately timeout (by pointing it to localhost).
Suggested fix: If elastic search cannot be connected to consistently for 5 minutes automatically disable it for 5 minutes.
Suggested fix: If elastic search cannot be connected to consistently for 5 minutes automatically disable it for 5 minutes.