From 465b43d88d10ea2d95033080b4cefe2ceb13d698 Mon Sep 17 00:00:00 2001 From: Niko PLP Date: Wed, 14 Aug 2024 00:12:37 +0300 Subject: [PATCH] reconnecting attempts every 5 secs --- ng-app/src/locales/en.json | 2 +- ng-app/src/store.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ng-app/src/locales/en.json b/ng-app/src/locales/en.json index 59c3f4e..a5f4b76 100644 --- a/ng-app/src/locales/en.json +++ b/ng-app/src/locales/en.json @@ -53,7 +53,7 @@ "not_found" : "Document not found", "empty_container": "Container is empty.", "not_found_details_online" : "The document could not be found locally on this device, nor on the broker.", - "not_found_details_offline" : "The document could not be found locally on this device, and it seems like you are offline, so it could not be retrieved from any broker neither.

If you are opening this document for the first time on this device, you have to be online now so the document can be fetched.

We will try connecting and fetching it every 20 seconds.", + "not_found_details_offline" : "The document could not be found locally on this device, and it seems like you are offline, so it could not be retrieved from any broker neither.

If you are opening this document for the first time on this device, you have to be online now so the document can be fetched.

We will try connecting and fetching it every 5 seconds.", "cannot_load_offline": "You are offline and using the web app. There is currently a limitation on local storage within the Web App, and you need to connect to the broker every time you login with the Web App.

For now, the Web App does not keep a local copy of your documents. due to the limit of 5MB in localStorage. We will remove this limitation soon. Stay tuned!

Check your connectivity status in the ", "header": { "buttons": { diff --git a/ng-app/src/store.ts b/ng-app/src/store.ts index 0038791..97493d4 100644 --- a/ng-app/src/store.ts +++ b/ng-app/src/store.ts @@ -219,12 +219,12 @@ const updateConnectionStatus = async ($connections: Record) => { connection => connection.error === "ConnectionError" ); if (should_reconnect) { - console.log("will try reconnect in 20 sec"); + console.log("will try reconnect in 5 sec"); next_reconnect = setTimeout(async () => { await reconnect(); next_reconnect = null; - }, 20000); + }, 5000); } if (is_connected) {