Class: Appwrite::Health
- Defined in:
- lib/appwrite/services/health.rb
Instance Method Summary collapse
-
#get ⇒ HealthStatus
Check the Appwrite HTTP server is up and responsive.
-
#get_antivirus ⇒ HealthAntivirus
Check the Appwrite Antivirus server is up and connection is successful.
-
#get_cache ⇒ HealthStatus
Check the Appwrite in-memory cache server is up and connection is successful.
-
#get_db ⇒ HealthStatus
Check the Appwrite database server is up and connection is successful.
-
#get_queue_certificates ⇒ HealthQueue
Get the number of certificates that are waiting to be issued against [Letsencrypt](letsencrypt.org/) in the Appwrite internal queue server.
- #get_queue_functions ⇒ HealthQueue
-
#get_queue_logs ⇒ HealthQueue
Get the number of logs that are waiting to be processed in the Appwrite internal queue server.
-
#get_queue_webhooks ⇒ HealthQueue
Get the number of webhooks that are waiting to be processed in the Appwrite internal queue server.
-
#get_storage_local ⇒ HealthStatus
Check the Appwrite local storage device is up and connection is successful.
-
#get_time ⇒ HealthTime
Check the Appwrite server time is synced with Google remote NTP server.
Methods inherited from Service
Constructor Details
This class inherits a constructor from Appwrite::Service
Instance Method Details
#get ⇒ HealthStatus
Check the Appwrite HTTP server is up and responsive.
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'lib/appwrite/services/health.rb', line 11 def get() path = '/health' params = { } headers = { "content-type": 'application/json', } @client.call( method: 'GET', path: path, headers: headers, params: params, response_type: Models::HealthStatus ) end |
#get_antivirus ⇒ HealthAntivirus
Check the Appwrite Antivirus server is up and connection is successful.
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/appwrite/services/health.rb', line 34 def get_antivirus() path = '/health/anti-virus' params = { } headers = { "content-type": 'application/json', } @client.call( method: 'GET', path: path, headers: headers, params: params, response_type: Models::HealthAntivirus ) end |
#get_cache ⇒ HealthStatus
Check the Appwrite in-memory cache server is up and connection is successful.
58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 |
# File 'lib/appwrite/services/health.rb', line 58 def get_cache() path = '/health/cache' params = { } headers = { "content-type": 'application/json', } @client.call( method: 'GET', path: path, headers: headers, params: params, response_type: Models::HealthStatus ) end |
#get_db ⇒ HealthStatus
Check the Appwrite database server is up and connection is successful.
81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 |
# File 'lib/appwrite/services/health.rb', line 81 def get_db() path = '/health/db' params = { } headers = { "content-type": 'application/json', } @client.call( method: 'GET', path: path, headers: headers, params: params, response_type: Models::HealthStatus ) end |
#get_queue_certificates ⇒ HealthQueue
Get the number of certificates that are waiting to be issued against [Letsencrypt](letsencrypt.org/) in the Appwrite internal queue server.
106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 |
# File 'lib/appwrite/services/health.rb', line 106 def get_queue_certificates() path = '/health/queue/certificates' params = { } headers = { "content-type": 'application/json', } @client.call( method: 'GET', path: path, headers: headers, params: params, response_type: Models::HealthQueue ) end |
#get_queue_functions ⇒ HealthQueue
129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 |
# File 'lib/appwrite/services/health.rb', line 129 def get_queue_functions() path = '/health/queue/functions' params = { } headers = { "content-type": 'application/json', } @client.call( method: 'GET', path: path, headers: headers, params: params, response_type: Models::HealthQueue ) end |
#get_queue_logs ⇒ HealthQueue
Get the number of logs that are waiting to be processed in the Appwrite internal queue server.
153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 |
# File 'lib/appwrite/services/health.rb', line 153 def get_queue_logs() path = '/health/queue/logs' params = { } headers = { "content-type": 'application/json', } @client.call( method: 'GET', path: path, headers: headers, params: params, response_type: Models::HealthQueue ) end |
#get_queue_webhooks ⇒ HealthQueue
Get the number of webhooks that are waiting to be processed in the Appwrite internal queue server.
177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 |
# File 'lib/appwrite/services/health.rb', line 177 def get_queue_webhooks() path = '/health/queue/webhooks' params = { } headers = { "content-type": 'application/json', } @client.call( method: 'GET', path: path, headers: headers, params: params, response_type: Models::HealthQueue ) end |
#get_storage_local ⇒ HealthStatus
Check the Appwrite local storage device is up and connection is successful.
200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 |
# File 'lib/appwrite/services/health.rb', line 200 def get_storage_local() path = '/health/storage/local' params = { } headers = { "content-type": 'application/json', } @client.call( method: 'GET', path: path, headers: headers, params: params, response_type: Models::HealthStatus ) end |
#get_time ⇒ HealthTime
Check the Appwrite server time is synced with Google remote NTP server. We use this technology to smoothly handle leap seconds with no disruptive events. The [Network Time Protocol](en.wikipedia.org/wiki/Network_Time_Protocol) (NTP) is used by hundreds of millions of computers and devices to synchronize their clocks over the Internet. If your computer sets its own clock, it likely uses NTP.
229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 |
# File 'lib/appwrite/services/health.rb', line 229 def get_time() path = '/health/time' params = { } headers = { "content-type": 'application/json', } @client.call( method: 'GET', path: path, headers: headers, params: params, response_type: Models::HealthTime ) end |