1 | <?php |
||
10 | class ServersArePingable implements Check |
||
11 | { |
||
12 | protected const DEFAULT_TIMEOUT = 5; |
||
13 | |||
14 | /** @var Collection */ |
||
15 | protected $notReachableServers; |
||
16 | |||
17 | /** |
||
18 | * The name of the check. |
||
19 | * |
||
20 | * @param array $config |
||
21 | * @return string |
||
22 | */ |
||
23 | public function name(array $config): string |
||
27 | |||
28 | /** |
||
29 | * Perform the actual verification of this check. |
||
30 | * |
||
31 | * @param array $config |
||
32 | * @return bool |
||
33 | * @throws InvalidConfigurationException |
||
34 | */ |
||
35 | public function check(array $config): bool |
||
58 | |||
59 | /** |
||
60 | * The error message to display in case the check does not pass. |
||
61 | * |
||
62 | * @param array $config |
||
63 | * @return string |
||
64 | */ |
||
65 | public function message(array $config): string |
||
75 | |||
76 | /** |
||
77 | * Parses an array of servers which can be given in different formats. |
||
78 | * Unifies the format for the resulting collection. |
||
79 | * |
||
80 | * @param array $servers |
||
81 | * @return Collection |
||
82 | * @throws InvalidConfigurationException |
||
83 | */ |
||
84 | private function parseConfiguredServers(array $servers): Collection |
||
111 | } |
||
112 |