![]() |
MySQL 9.5.0
Source Code Documentation
|
#include <shared_quarantine_handler.h>
Public Types | |
| using | update_callback_type = std::function< bool(mysql_harness::Destination, bool)> |
| using | is_quarantined_callback_type = std::function< bool(mysql_harness::Destination)> |
| using | stop_callback_type = std::function< void()> |
| using | refresh_callback_type = std::function< void(const std::string &, const bool, const AllowedNodes &)> |
Public Member Functions | |
| void | on_update (update_callback_type clb) |
| Register a callback that can to be used to add a destination candidate to the quarantine. More... | |
| bool | update (const mysql_harness::Destination &dest, bool success) |
| void | on_is_quarantined (is_quarantined_callback_type clb) |
| Register a callback that can be used to check if the given destination candidate is currently quarantined. More... | |
| bool | is_quarantined (const mysql_harness::Destination &dest) const |
| void | on_stop (stop_callback_type clb) |
| Register a callback that can be used to stop the unreachable destination candidates quarantine. More... | |
| void | stop () |
| void | on_refresh (refresh_callback_type clb) |
| Register a callback used for refreshing the quarantined destinations when there are possible changes in the destination candidates set. More... | |
| void | refresh (const std::string &instance_name, bool some_bool, const AllowedNodes &allowed_nodes) |
| void | reset () |
| Unregister all of the destination candidates quarantine callbacks. More... | |
Private Attributes | |
| update_callback_type | on_update_ |
| is_quarantined_callback_type | on_is_quarantined_ |
| stop_callback_type | on_stop_ |
| refresh_callback_type | on_refresh_ |
| using SharedQuarantineHandler::is_quarantined_callback_type = std::function<bool(mysql_harness::Destination)> |
| using SharedQuarantineHandler::refresh_callback_type = std::function<void( const std::string &, const bool, const AllowedNodes &)> |
| using SharedQuarantineHandler::stop_callback_type = std::function<void()> |
| using SharedQuarantineHandler::update_callback_type = std::function<bool(mysql_harness::Destination, bool)> |
|
inline |
|
inline |
Register a callback that can be used to check if the given destination candidate is currently quarantined.
| [in] | clb | Callback called to check if the destination is quarantined. |
|
inline |
Register a callback used for refreshing the quarantined destinations when there are possible changes in the destination candidates set.
| [in] | clb | Callback called on metadata refresh. |
|
inline |
Register a callback that can be used to stop the unreachable destination candidates quarantine.
| [in] | clb | Callback called to remove all destinations from quarantine. |
|
inline |
Register a callback that can to be used to add a destination candidate to the quarantine.
| [in] | clb | Callback called to quarantine a destination. |
|
inline |
|
inline |
Unregister all of the destination candidates quarantine callbacks.
|
inline |
|
inline |
|
private |
|
private |
|
private |
|
private |