mirror of
https://github.com/openhab/openhab-addons.git
synced 2025-01-10 15:11:59 +01:00
Adding scheduled reconnection on timeout (#13130)
Signed-off-by: clinique <gael@lhopital.org>
This commit is contained in:
parent
d724b7f075
commit
53b26809d8
@ -142,7 +142,9 @@ public class OpenUVBridgeHandler extends BaseBridgeHandler {
|
||||
logger.debug("{} : {}", statusMessage, jsonData);
|
||||
}
|
||||
} catch (IOException e) {
|
||||
statusMessage = e.getMessage();
|
||||
statusMessage = String.format("@text/offline.comm-error-ioexception [ \"%s\",\"%d\" ]", e.getMessage(),
|
||||
RECONNECT_DELAY_MIN);
|
||||
scheduleReconnectJob(RECONNECT_DELAY_MIN);
|
||||
} catch (OpenUVException e) {
|
||||
if (e.isQuotaError()) {
|
||||
LocalDateTime nextMidnight = LocalDate.now().plusDays(1).atStartOfDay().plusMinutes(2);
|
||||
|
@ -67,6 +67,7 @@ offline.config-error-unknown-apikey = Parameter 'apikey' must be configured.
|
||||
offline.config-error-invalid-refresh = Parameter 'refresh' must be higher than 3 minutes to stay in free API plan.
|
||||
offline.comm-error-quota-exceeded = Quota Exceeded, going OFFLINE for today, will retry at : {0}
|
||||
offline.comm-error-faultly-service = Service not responding, will reconnect in {0} minutes
|
||||
offline.comm-error-ioexception = IOException : `{0}`, will reconnect in {1} minutes
|
||||
offline.invalid-json = Invalid JSON received when calling `{0}`
|
||||
offline.api-key-not-recognized = Service error while API key is known correct, will reconnect in {0} minutes
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user