简体   繁体   中英

Mechanism to maintain service when internet connection is lost with application server

We currently have a centralised web app and database (running on glassfish and oracle) which is accessed from multiple stations distributed about the country.

At the stations there is data entered into and read from the system (through the browser).

When the (external) connection goes down between the station and the centralized web app we would like for the stations to continue to function - store and present data, then when the connection returns the data is pushed back into the central server maintaining database integrity.

Given that we would be willing to change our app server or database if it was worth it, how is this best handled, is there any out of the box solution for this?

Install the servers at the individual locations, replicate what you want to share across them "routinely", and leave all of the other centralized, but non-vital tasks (like, say, reporting) on the central system.

There is not "out of the box" solution. You system is centralized for whatever reason it's centralized. You're asking for it to be decentralized. By doing so you need to reconsider why it's centralized in the first place, and what dependencies there are because of that centralization (such as each site having instant access to data at all of the other sites).

Address those issues of what you can do without, for how long, and how to share it, and then you can set up autonomous sites. The magnitude and complexity of this process is dependent upon you application and the services it supplies to the remote users.

If you can tolerate losing the current sessions I would point you to look for a distributed database (replication). Oracle probably supports it. In each office you would have a glassfish server

But it is going to cost a lot:

  • Licences
  • Hardware (servers)
  • Properly securing the server
  • (Lots of) tuning/rewritting to avoid new bottlenecks

Maybe it would be easier / cheaper if you chose to just use redundant internet access for all of your offices.

If you are willing to go cutting edge, then look into HTML 5 with Local Storage . Note that the local storage specification in HTML 5 is still in transition. The second link I included has a good fallback option for when HTML 5 local storage is unavailable. With the fallback option of Store.js, you won't even need to require your clients to use a modern browser, though it definitely helps.

Another option, if you are open to moving in that direction, is to use Adobe Flex 3 for your UI, talking through LiveCycle to your application hosted on Glassfish. There will be more moving parts and a steeper learning curve though.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM