The Great Mobile Slowdown

Document Sample
The Great Mobile Slowdown Powered By Docstoc
					                                              The Great Mobile Slowdown
                                              by Ido Safruti, Cotendo

You see it all the time in New York, San      significant cause of slow RTTs. HTTP is        data requests behind them slow down
Francisco and other parts of the world.       decades old but still dominates data           even more. This explains why a mobile
Someone standing on a sidewalk staring        traffic. Unfortunately, many of HTTPs          page load could lag for 15 seconds, but
at his smart phone. And staring. And          characteristics lead to increased              when the user reloads the page after
staring. Maybe they are watching a            latency. For example, HTTP allows              hitting the back button the page loads
video. But more likely they are waiting       processing of only one request per             far faster on the second try. The slow
for a page to load. And usually they          connection, this means that it takes a         TCP connection was broken and a faster
look annoyed, which is understandable.        minimum of an RTT to complete a single         one replaced it. Needless to say, this is
For pages loading over a fast WiFi            request, and prevents the browser from         not an efficient way to accelerate page
or home broadband connection the              using that connection to send additional       load speeds. The upshot of all this?
process averages 2 seconds or less.           requests until the response is fully           Network bandwidth matters far less
Supposedly fast wireless networks             received. On high latency connections,         than the underlying protocols for data
average page load times of 8 to 10            like mobile, this results in low utilization   delivery. So even when the network is
seconds. In places where high usage           of the connection, where most of the           not busy and the mobile device obtains
of data services congregate, like the         time is spent waiting on one of the            a speedy 8Mbps link, loading the same
big cities, those page loads can stretch      sides. Browsers circumvent this issue          page on mobile device will require far
to 20 seconds more. No, it’s not only         by launching as many as 6 separate             more time than loading that page on a
about the bandwidth or the backhaul, or       connections per hostname. But this             broadband connection.
overloaded towers either.                     solution is not a panacea as it adds
                                              complexity and processing overhead             One approach to address the HTTP
Rather, a major cause which is almost         on both the end device and the origin          problem is called “pipelining,” and in
never discussed for these waits is the        server.                                        fact is part of HTTP/1.1. This enables
disparity in the round-trip-times (RTT)                                                      the client to send additional requests
experienced by users on wireless versus       On wired broadband networks, where             on a connection before receiving the
wired broadband networks. In short,           the RTT is typically brief (10ms-50ms)         entire response back from the server.
the RTT from the mobile device to the         and connections are consistently fast          Pipelining actually enables better
mobile gateway and back is inevitably         and network conditions are reliable due        utilization of the link by eliminating
greater than the last mile RTT from the       to fixed nature of these networks, this        some unneeded round trips. However,
end user back and forth over cable,           additional overhead for delivering each        this approach has a few problems.
fiber or DSL broadband connections            object is barely noticeable. But on 3G         Most browsers don’t support pipelining.
at home or at work. That’s despite the        and other mobile data networks, where          Some servers and network proxies
best efforts of legacy Content Delivery       the RTT from a mobile device to the            don’t support it, either. Further, HTTP
Networks (CDNs) to speed up delivery          mobile gateway alone is typically              pipelining cannot handle the sequencing
times and cut latency, both of which will     120ms - 200ms, the dozens of                   of requests and responses. So for a
boost user engagement. It’s important         requests for objects for a page cause          page to load properly the responses
to note, too, that very small changes to      compounding latency that can easily            must be sent in the exact same order
the data footprint of mobile Websites         add up to seconds spent waiting on a           as the requests. In that case, an object
can result in large reductions in content     spinning icon on the screen. Naturally,        which is slow to serve will slow the
latency. So let’s examine this question       this leads to user abandonment of              entire connection, blocking further
at three different levels and discuss         content and links.                             requests.
why mobile content delivery is so much
slower and what can be done to fix that       TCP, too, compounds the problem                Google is currently championing a
problem.                                      as its efficiency and throughput is            newer protocol called SPDY that is
                                              dramatically impacted by variable and          fully multiplexed, allows for servers
At the network level, the HTTP                inconsistent RTTs on the link. This            to initiate a request (“push”), permits
request-response protocol is a                ensures that those connections and the         header compression, and other latency

  © 2011 Cotendo, Inc. All rights reserved.

            866.749.6462 | INTL +44 20 33188363 | |
reduction techniques presently missing        images that are optimized for a Web          that type of handset. By pushing logic
in HTTP. Google has made SPDY an              page or applications on that specific        closer and closer to the end user, CDNs
open standard and released their              mobile device. Another way to speed          will push the envelope on what can
implementation as open-source code.           up mobile delivery is to simply speed        and cannot be cached and stored in
They have also engineered SPDY into           up the delivery of an entire Website.        the edge of the network. Further, with
the Chrome browser and will likely            This whole site acceleration involves        these capabilities CDNs can expand the
include it in a future build of the           optimization of all the content – both       number of ways they cache. Whereas
Android operating system used by tens         static and dynamic - coming off a Web        legacy CDNs can cache only by URL and
of millions of mobile devices. However,       server. Site Acceleration technologies       filename, newer CDNs with advanced
greater client-side adoption of SPDY (by      generally compress JavaScript, CSS and       edge logic can cache information
handset makers and mobile software            other components of a typical Website        based on the device, the location,
developers) will take some time.              that may be served uncompressed from         network conditions, and many other
                                              the content origin Web server. Whole         key parameters. This advanced caching
With regard to the problem of                 site acceleration shaves off additional      will dramatically reduce latency and will
TCP-induced latency, CDN operators are        latency and is particularly important for    speed up content delivery because far
creating special algorithms to optimize       mobile devices.                              fewer of the dozens of different data
TCP delivery based on specific network                                                     requests required to load an average
conditions. This will make TCP requests       At the business logic level, the nature      Web page will need to travel all the way
“smarter” and less likely to create a         of mobile behavior comes into play.          back to the origin server. Rather, a far
downward spiral of latency resulting          Mobile interactions tend to focus on         higher percentage of those requests will
from a slow request continuing to             highly personal activities such as           be fulfilled by pulling cached data stored
languish in the back of the TCP priority      communication, use of social networks,       in the edge of the network.
queue. CDNs are also figuring out new         and local services (or location based
ways to reduce the time it takes for          services). These may include activities      While consumers are waiting for their
each TCP request to be processed,             such as checking the weather, traffic        mobile devices to speed up, carriers
thereby minimizing the impacts of             data, or looking at movie times around       and content delivery networks will
compounding latency.                          you. Caching this type of information        continue to work on a variety of new
                                              on a CDN is particularly difficult           technologies to speed up content to
At the content level, delivering Web          because it is personalized to a user or      mobile devices around the world.
pages and data to mobile devices is far       geographically fragmented into very          Bringing content and logic closer to the
more complicated than delivering to           small increments (Think how many             user, more intelligent content caching,
PCs or laptops over wired broadband           movie theaters there are in a large city     optimizing TCP delivery for network
networks. As the link to the device           and you get the idea). Users requesting      conditions, shrinking file sizes with
may be shaky, reducing the overall            this data often experience painfully slow    compression, and eliminating unneeded
payload to deliver, reduces the chance        loading pages caused by round trips all      round trips on HTTP are all needed to
for errors, and ensures faster delivery,      the way back to the origin server.           reduce latency and improve end-user
within less RTTs. For instance, images                                                     experiences on the mobile Internet. The
easily served over wired connections          Some of the newer CDN technologies           drive to implement and propagate these
may bog down mobile networks when             can address the logic level in a number      technology improvements is spurred on
network connectivity is weak. Adaptive        of innovative ways. First, they can more     by the fast growth of the various types
Image Compression, a technology               intelligently cache information close        of mobile applications and data usage
that dynamically compresses image             to end users with mobile devices, and        patterns (dynamic, personal,
content based on the recipient device’s       use the location as a cache-key. So,         location-based content applications)
display capabilities and a real-time          for example, a weather site can, with        that most benefit from these
assessment of the specific user’s mobile      this type of logic, cache appropriate        newer mobile content acceleration
throughput and network conditions, is         detailed weather information for a user      technologies. As a result of these and
one way to address this challenge. With       in the CDN based on their initial GPS        many other newer technologies, we
this technology, a CDN generates on           contact point. This weather data can         hope that soon a person standing on
the fly different versions of the same        be later served to other users located a     the street staring at their smart phone
image with varying image sizes and            few blocks away, eliminating the need        waiting for a page to load is a far rarer
data footprints. As the CDN detects           for additional round trips. Alternatively,   occurrence.
the type of device and throughput             the CDN can quickly detect the type of
conditions for the image request,             device and cache assets in the edge
the CDN node will serve compressed            of the network that are required for

  © 2011 Cotendo, Inc. All rights reserved.

            866.749.6462 | INTL +44 20 33188363 | |

Shared By:
Description: Some of the newer CDN technologies can address the logic level in a number of innovative ways. First, they can more intelligently cache information close to end users with mobile devices, and use the location as a cache-key. So, for example, a weather site can, with this type of logic, cache appropriate detailed weather information for a user in the CDN based on their initial GPS contact point. This weather data can be later served to other users located a few blocks away, eliminating the need for additional round trips.