5 minutes

HTML5 On-Device Caching – What It Is and What It Does for Mobile Cloud Computing


It’s hard to ignore the deafening buzz in the air these days about cloud computing. But when you consider the numerous advantages this maturing technology is capable of offering, there is nothing cloudy about its future. So what exactly is this cloud and what’s the fuss all about?

Well, the “cloud” is sometimes used as a metaphor for the Web itself, but it is actually more than that. It is a collection of numerous data centers worldwide that house the resources needed to offer various forms of computing services. And loosely defined, cloud computing can be considered a general term describing the delivery of those services over the Internet. The services themselves can include software applications, storage devices, development platforms, and much more.

The advantages of cloud computing are numerous. Users have instant remote access to applications and data when they need them. Since they are hardware independent, data and images are transportable and therefore can be backed up and recovered frequently. Resources can be ramped up or scaled down as needed. And the costs normally associated with maintaining software and equipment are either greatly reduced or eliminated altogether.

So with all these advantages, it’s not hard to understand how cloud computing is rapidly migrating from static platforms onto mobile ones. In fact, a 2010 study by Juniper Research forecasted an 88 percent growth in the market over a five-year period for mobile apps by the year 2014. And as time goes on, an increasing percentage of these applications will be coming from the mobile cloud instead of being downloaded and installed on smartphones and other mobile devices. Not only that, but new types of mobile cloud handsets, essentially less powerful but more specialized smartphones, are already starting to emerge. And these devices are specifically oriented toward running mobile cloud apps. It’s not surprising that the growing proliferation of mobile cloud apps has already spawned the creation of a new name – mobile cloud computing, which essentially means that the processing of applications and the storage and retrieval of their data are being performed by a cloud-based infrastructure rather than being done on the mobile device itself.

But advantages notwithstanding, mobile cloud computing is not without its downside. The inherent constraints of wireless networks and devices pose unique challenges to mobile cloud computing that are much less prevalent in static cloud computing. For example, as everyone who has used a smartphone is well aware, problems such as intermittent connectivity, inconsistent data rates, and longer network latencies come with the territory and can often become the rule rather than the exception. These annoyances are bad enough, but they become more than trivial when you are relying on continuous access to the “cloud” and suddenly discover that there is no longer a cloud in the sky.

Fortunately, there is a white knight that has come riding to the rescue. It goes by the name of HTML5, and it functions as the fifth and latest revision of HTML, the Web’s markup language. HTML5 was developed with the mobile world in mind, and this is evidenced by some of its features which mitigate or eliminate many of the pitfalls that come with mobile cloud computing. One of the most significant of these features is known as on-device caching.

To help fully understand what on-device caching is and what it does, let’s step back a minute and look at the definition of a cache and the concept of caching in general. A cache is a storage mechanism for holding recently-used information in a close and convenient place where it can be accessed extremely fast. Web browsers such as Internet Explorer use caches to store the pages, images, and Internet addresses of recently visited sites on your computer’s hard drive. The existence of a cache basically means that when you visit a page you have recently been to, that page and its images and content don’t necessarily have to be downloaded to your computer all over again. Accessing the cache stored on your computer’s hard drive is significantly faster than accessing the Internet, and therefore the practice of caching websites can speed up browsing tremendously.

HTML5 was developed with a high capability for offline data storage, and it does this via two primary tools: application caching and something called “client-side storage”.  The differences between the two are subtle yet significant. Application caching retains the application’s core logic and user interface. In the case of a game, for example, application caching involves saving the game’s logic (i.e., the initial HTML document, the CSS, the JavaScript), heavily used game images and icons, and sound samples on the local hard drive. As a result, these things will load immediately every time the user accesses the application. Client-side storage, on the other hand, saves specific data the user may have generated during the previous session, or certain resources the user has expressed interest in. In our game example, client-side storage would allow the user to restore the state of the game from a previous position and pick up seamlessly from where he left off.

Online HTML Email Template Builder

With Postcards you can create and edit email templates online without any coding skills! Includes more than 100 components to help you create custom emails templates faster than ever before. Try now for free!

Learn MoreOther Products

Now take these same capabilities and transport them to the mobile world, where the caching can get done onto the mobile device itself. It’s not hard to see how HTML5’s capability to perform on-device caching solves many of the former problems associated with mobile cloud computing. On-device caching means fewer round-trips are required between the device and the cloud server, meaning that it’s now possible to run apps effectively on the device even during periods of interruption or discontinuity in mobile connectivity. The net result is that just about anything that works on an HTML5 website as viewed within a desktop browser pretty much works now on a mobile device too. No wonder almost all modern smartphones now have HTML5-capable browsers!

Here are just a few examples of popular mobile apps that take advantage of on-device caching:

  • Google Maps for Android: The software takes into account those areas where the user transits most often and preloads map data for those areas, ensuring continuity through loss of signal.
  • CIA World Factbook (for Blackberry and Android): Country and territory information, once downloaded, is cached on the device. This means that no Internet connection or data transfer is required when roaming in a foreign country.
  • The Mango upgrade to the Windows Phone operating system touts a huge improvement in functionality due to on-device caching, including a much improved on-screen scrolling capability. Gone are the old pauses or screen freezes when moving fast in a list of apps.
  • NewsRob Pro (an RSS reader) integrates directly with a Google Reader account and takes advantage of on-device caching to allow reading without being on a network.

There’s no stemming the growing tide of popularity of cloud computing. There are way too many good things about it and there is little doubt the “cloud” is here to stay. But cloud computing is no longer a game only played by desktop users. Happily, mobile users are now active players too. The days when mobile was the problem child of the cloud computing world are over. Largely through on-device caching, HTML5 has restored first-class citizenship to mobile devices and made mobile cloud computing a fully functioning reality.

Sue Poremba

Sue Poremba blogs for Rackspace Hosting. Rackspace Hosting is the service leader in cloud computing, and a founder of OpenStack, an open source cloud operating system. The San Antonio-based company provides Fanatical Support to its customers and partners, across a portfolio of ITservices, including Managed Hosting and Cloud Computing.

Posts by Sue Poremba

Super-Intuitive Drag & Drop Template Generator

Create beautiful responsive emails and newsletters easily.

Learn more Try Free
Cookie Icon
We use cookies to ensure that we give you the best experience on our website.
  • I disagree
  • I agree