0

We've developed a web application which is hosted on premises available for people in the shop floor via Wifi. However, the wifi signal is not reliable and it's not possible to use wired network or improve the signal.

I am looking for a solution to handle this issue. Is there a way to put the http requests into a local queue and process it asynchronously at the background? If so, how to do it? Or is there any other alternative approach?

Any thoughts are greatly appreciated.

tereško
  • 58,060
  • 25
  • 98
  • 150
Dan
  • 63
  • 1
  • 1
  • 7

2 Answers2

0

I would recommend to build the web app with angularjs or another javascript framework of your choice. Once the user has loaded the site you can perform asynchronous ajax/http requests to load the required data and the web app will never reload the entire page.

In case one http request fails you can implement that the web app should try one more time or whatever :)

nipeco
  • 760
  • 2
  • 9
  • 24
  • Thank you very much for your comment, nipeco. This should be definitely achieved with an asynch request. – Dan Nov 25 '15 at 10:04
0

I have the same problem in the company where I work, there are certain places where the WiFi can not reach, and the system needs to get information from the DB in order to show that info to the user and then upload some new info.

Part of this system is done with iPads, so to solve the problem I use LocalStorage to store a JSON object that contains the info the user need to work, I store the info that is going to be uploaded in another JSON object, and when there is a connection available the info is Uploaded.

Hope it helps

Community
  • 1
  • 1
Enrique Zavaleta
  • 2,098
  • 3
  • 21
  • 29
  • Thanks very much, Enrique, for your idea. But, how do you know if the connection is back on? Have you got something written (e.g. with JavaScript) to check it at the regular interval running locally from the browser? – Dan Nov 24 '15 at 16:58
  • In my case, the user is the one who decide when the information is uploaded, because I can store a _lot of items_ and the user could want to still working with more, but [there](http://stackoverflow.com/questions/2384167/check-if-internet-connection-exists-with-javascript) [are](http://stackoverflow.com/questions/189430/detect-that-the-internet-connection-is-offline) [different](https://github.com/hubspot/offline) ways to accomplish that – Enrique Zavaleta Nov 24 '15 at 17:23