Majid Al-RaimiEdge, fog and cloud

COE 558Lecture 01Part 08

Edge, fog and cloud

The layers of the E2C continuum from mist to regional cloud, their latency, resources and typical roles.

Concepts
4
Slides
56-60
Reading
24 min
Understood
0/4 concepts

Why this part matters

Every system you design in this course, and the research project itself, starts with one question: where does each piece of work run? This part gives you the map. It is a chain of places from the device in your hand to a hyperscale data center. Each step outward buys processing power and storage, and each step costs latency. Exam questions on placement, and the mapping problems in the next part, both assume you can read this map fluently.

By the end you can

  1. Explain why the server side of a system is a continuum of possible locations, and why the location a user is served from sets the latency they feel.
  2. Name the three layers of the E2C continuum and its seven stages in order from device to cloud, with a real product or board for each.
  3. Explain the core trade of the continuum: resources and coverage grow outward while proximity falls, and argue it with propagation, hops and real millisecond thresholds.
  4. Apply the placement rule, and justify a placement with latency, processing and storage needs, and cost.
  5. Spot ambiguous terminology, such as near versus far edge, and a mislabelled microcontroller board.

Start with something you do every week. When you press play on Netflix in Dhahran, the video bytes do not cross an ocean from a data center in the United States. Netflix runs its own delivery network, Open Connect, and places caching appliances inside the networks of internet service providers and at Internet Exchange Points. The first bytes of your episode travel a few kilometres and a few router hops, not thousands of kilometres and dozens of hops.

In the client-server model of the earlier parts, the Server looked like one box at the far end of the line. The Netflix example shows why that picture is too simple. Between the Client and the origin data center there are several stops, and each stop is a possible home for code or data. Moving work from one stop to another moves you along a continuum of latencies. A stop closer to the client means a shorter path, so less Propagation delay and fewer routers where a packet can wait in a queue.

The consequence for users is striking. The same service, running the same code, can make one user happy and another angry, and the only difference is where the service runs relative to each of them. A viewer served from a cache in their own city sees the video start at once; a viewer served from another continent watches a spinner. Placement is therefore not an operations detail. It is part of the design of the application.

The idea is older than cloud computing. Mahadev Satyanarayanan traces edge computing back to content delivery networks (CDNs) such as Akamai in the late 1990s: a CDN uses nodes close to users to prefetch and cache web content. Edge computing generalises that idea. Instead of only caching bytes near users, you run arbitrary code there. The rest of this part names the stops on the line and the trade each one offers; the course as a whole is about deciding what to put at each one, which is the heart of the Edge-to-cloud (E2C) continuum.

Recall

Why does Netflix place Open Connect appliances inside ISP networks instead of serving every stream from a central data center?

It shortens the path to the viewer: fewer kilometres, so less propagation delay, and fewer hops, so less queueing. Playback starts quickly and does not buffer.

Quick check

Why does caching a video at Layer 1 near the viewer reduce buffering?

To reason about placement you need names for the stops. Follow one request from a smart doorbell outward. The doorbell's own small chip decides that the button was pressed. The event goes to your home Wi-Fi router. From there it reaches a site run by your mobile or broadband operator nearby, for example an AWS Wavelength Zone, which places AWS compute and storage at the edge of a carrier's 5G network. Next it may reach a metro micro data center that collects events from many homes. Finally it lands in an AWS Region, inside one of its Availability Zones.

Those stops group into three coarse layers. The Cloud is farthest from the client. The Fog is the middle: mini data centers or intermediate nodes that process data partially. The Edge is closest to the client. Each Layer then splits into sublayers, which gives a seven-stage chain:

  1. Device: the phone, sensor or doorbell itself.
  2. Mist: tiny compute on or right beside the device.
  3. Near edge: the home router or on-premises gateway.
  4. Far edge: a nearby telco data center or carrier site.
  5. Fog: metro nodes, micro data centers and aggregation nodes.
  6. Regional cloud: a cloud region close to the user's country.
  7. Cloud: the full hyperscale infrastructure of availability zones and regions.
Seven stages light up outward from the device, then fold into three layers: edge, fog and cloud.

The chain is a spectrum, not a set of sealed boxes, which is exactly why it is called a continuum. Each stage is simply one more Server layer where you could run part of your application, and the boundaries between neighbouring stages are soft.

The standards agree on the shape and admit the edges are fuzzy. The term fog comes from Bonomi and colleagues at Cisco in 2012, who wrote that fog computing extends the cloud paradigm to the edge of the network. NIST SP 500-325 later formalised it: fog nodes sit between smart end devices and centralised cloud services, and can be physical (gateways, switches, routers, servers) or virtual (virtual switches, virtual machines, cloudlets). It describes mist as a lightweight, rudimentary form of fog computing that uses microcomputers and microcontrollers to feed fog nodes, and it does not treat mist as a mandatory layer.

The cloud sublayers, precisely

Unlike fog and mist, the cloud's own sublayers have exact definitions from the providers. Learn them from AWS, since the terms are used across the industry.

Cloud sublayers as AWS defines them

Region
A separate geographic area that contains several isolated availability zones.
Availability Zone (AZ)
One or more discrete data centers with redundant power, networking and connectivity inside a Region.
Distance between AZs
Within 100 km (60 miles) of each other in the same Region.
Global footprint
124 AZs in 39 Regions at the time of writing. This count grows over time.

Real products at each layer

Commercial offerings make the stages concrete. Notice that the far edge alone has two flavours: sites inside a carrier's network, and sites in metro data centers near large populations.

LayerProduct or standardWhat it is
Far edge, telcoAWS WavelengthAWS compute and storage deployed at the edge of carriers' 5G networks, managed from the parent Region.
Far edge, metroAWS Local ZonesAWS resources placed close to large population and industry centres for low-latency applications such as real-time gaming, live streaming and AR/VR.
Far edge, metroCloudflare WorkersCode runs in lightweight isolates across 348 cities; about 95% of the connected population is within 50 ms of a Cloudflare data center.
On-premises edge or fogAzure Stack Edge1U rack appliances with 1 to 2 NVIDIA T4 GPUs, used in Azure private multi-access edge compute (MEC, the architecture standardised by ETSI).
CloudAWS Regions and AZsFull data centers, 124 AZs worldwide, for pooled compute and long-term storage.
Where commercial edge and cloud offerings sit on the chain

Recall

List the seven stages of the E2C chain in order from the user outward, and name the sublayers of the cloud.

Device, mist, near edge, far edge, fog, regional cloud, cloud. The cloud is divided into regions, and each region into availability zones.

Quick check

On the lecture's seven-stage chain, which example belongs to the far edge?

Names alone do not tell you where to run anything. What makes the continuum useful is that every stage offers a different bargain, and the bargain changes steadily as you move outward. Put a real part at each layer and the bargain becomes concrete. A Raspberry Pi Pico can decide "button pressed, turn on the light" instantly, and not much more; an AWS Region pools entire data centers. The steps between them fill in the gradient.

LocationProximityResourcesTypical roleExample hardwareVerified spec
MistClosestVery limitedImmediate, local decisionsRaspberry Pi Pico (RP2040)133 MHz, 264 kB SRAM, 2 MB flash
Near edgeVery closeLimited to moderateLocal processingRaspberry Pi 4 Model B4 cores at 1.8 GHz, 1 to 8 GB RAM
Far edgeCloseModerate to highLow-latency applicationsJetson Orin Nano Super, or a Wavelength Zone instance67 TOPS, 8 GB RAM, 7 to 25 W
Fog or regionalIntermediateHighAggregation and coordinationMetro micro data center, or an on-premises Azure Stack Edge appliance at a large site1U with 1 to 2 NVIDIA T4 GPUs
CloudDistantVery highLarge-scale computation and storageAWS Region124 AZs, each one or more data centers
The layers compared, with real hardware

Two gradients running in opposite directions

Read the table top to bottom and two things change together. Proximity falls and resources rise. Each step outward serves more users over a wider area with bigger hardware, but sits further away. Bonomi and colleagues put it in one line: the higher the tier, the wider the geographical coverage and the longer the time scale.

Resources rise from mist to cloud while proximity falls. The two guide lines slope in opposite directions: each step outward trades proximity for resources.

The role column follows from the resources column. An immediate decision needs no network at all, so it can live on a tiny chip. Aggregation needs a view of many sources, so it lives where many streams meet. Large-scale computation needs pooled capacity, so it lives in a data center. In Bonomi's smart grid example, the first tier runs control loops that react in milliseconds to sub-seconds, higher tiers run real-time analytics over seconds to minutes and transactional analytics over days, and the cloud keeps the data that must last.

Why the latency side of the trade is physics

The cost of moving outward is latency, and a head-tracked virtual reality headset shows how hard that cost can bite. Satyanarayanan reports that the display must respond to head movement in under 16 ms to feel stable. Citing Ang Li and colleagues, he gives an average round-trip time of 74 ms from 260 vantage points to their best Amazon EC2 data center, before the wireless first hop is even added. A VR application that renders in a distant cloud region therefore cannot meet its target, whatever the server does. The same application rendering on a cloudlet or far edge site one or two hops away can.

The reason comes straight from the previous part. The one-way latency to a layer can never be lower than the Latency lower bound, the distance divided by the speed of light. On top of that, every router on the way adds Queueing delay and processing. The Edge is one or a few hops away, the Fog is a metro away, and the Cloud may be a continent away. So latency, like resources, grows as you move outward: small at the edge, medium in the fog, large in the cloud.

Three rays leave the client together. The edge ray arrives first and the cloud ray last. Labels show one-way propagation in fibre to a nearby edge, a metro fog node and a distant cloud region.

Worked example

Propagation delay to each layer, in fibre

  1. Pick the speed

    Light in optical fibre travels at about 200,000 km/s, roughly two thirds of its speed in vacuum. The glossary's lower bound uses 300,000 km/s for vacuum; this example uses fibre because real links are fibre.
  2. Apply the formula

    dprop=distancespeedd_{prop} = \dfrac{\text{distance}}{\text{speed}}
    One-way propagation delay
  3. Edge and fog

    An edge node 1 km away gives about 0.005 ms. A fog node in the same metro, 50 km away, gives 0.25 ms.
  4. Cloud

    Assume a Gulf cloud region about 1,000 km of fibre away: 5 ms. Assume a US east coast region about 13,000 km of cable away (the straight-line distance is about 10,900 km, and cables do not follow straight lines): 65 ms one way, about 130 ms there and back.
  5. Result

    Propagation alone spans more than four orders of magnitude across the continuum. Queueing and processing at every hop come on top, and there are more hops to the cloud, so the real gap is usually even wider.

How low is low enough? Human perception gives useful targets. Satyanarayanan cites that people take about 370 to 620 ms to recognise a face and 300 to 450 ms to recognise speech, but only about 4 ms to tell that a sound is a human voice. He concludes that an end-to-end latency of a few tens of milliseconds is a safe but achievable goal. That is what a far edge footprint buys: Cloudflare reports that 95% of the connected population is within 50 ms of one of its data centers, and most are within 20 ms.

One nuance matters at PhD level. "Close" is about the network, not just the map. Satyanarayanan defines logical proximity by low latency, low jitter and high bandwidth, and warns that the question "how close is physically close enough?" has no abstract answer. A fog node behind a congested link can respond more slowly than a well-connected cloud availability zone, so the small, medium and large ordering is typical, not guaranteed.

Recall

As you move from mist to cloud, what happens to proximity, resources, latency and the typical role?

Proximity falls from closest to distant, so latency rises. Resources rise from very limited to very high. The role shifts from immediate local decisions, to local processing, to low-latency applications, to aggregation and coordination, to large-scale computation and storage.

Recall

Why can a head-tracked VR application not rely on a distant cloud region?

It needs under 16 ms for perceptual stability. The average round trip to the best EC2 data center, measured from 260 vantage points, was 74 ms, before the wireless hop. Propagation delay cannot be engineered away, so the rendering must move closer to the user.

Quick check

Which ordering lists layers from the fewest resources to the most?

Quick check

A factory robot arm must stop within milliseconds when a person steps into its path. Where should the stop decision run?

You now have both halves of the trade: processing power and storage increase from edge to fog to cloud, in the same direction as latency. Every step toward the cloud buys capacity and costs latency. That turns placement into a real decision, and the decision has three inputs: the latency requirement of the task, its processing and storage needs, and cost.

Picture a neighbourhood of smart doorbell cameras. Each camera, at the Edge, compares consecutive frames to detect motion, which is cheap arithmetic, and sends nothing while nothing moves. A fog node in the neighbourhood combines motion events from 200 cameras and door sensors to spot a pattern across streets, which is sensor data processing. The Cloud trains and hosts the large recognition model and keeps months of clips. One application, three layers, each doing the part it is equipped for.

Each task drops into hardware that can carry it: motion detection on a board, aggregation in a mini data center, AI in a data center.

The pattern generalises into a rule of thumb: put each task on the layer closest to the client that still has enough resources for it, and push data outward only when you need more compute, more storage or a wider view. Bonomi and colleagues describe the fog tier doing exactly this, filtering data to be consumed locally and sending the rest to higher tiers. Filtering early also saves bandwidth, since raw video is expensive to ship; Satyanarayanan lists scalability through edge analytics as a key benefit of cloudlets. Splitting one Service pipeline across layers like this is what the next part calls a Mapping.

TaskLayerWhy here
Detect motion in each frameEdge (on the camera)Must react instantly, needs little compute, avoids sending idle video.
Correlate events from many homesFog (neighbourhood node)Needs a view of many sources and moderate compute, still close enough for timely alerts.
Train and host the recognition model, archive clipsCloudNeeds pooled compute and very large storage; latency is not critical.
The doorbell pipeline, placed by the rule

Treat the typical roles (motion at the edge, sensor processing in the fog, AI in the cloud) as tendencies, not rules. Training and very large models belong in the cloud, but inference increasingly runs at the edge: a Jetson Orin Nano Super delivers 67 TOPS within 7 to 25 W. Edge platforms are not unlimited either. A Cloudflare Worker gets 128 MB of memory per isolate and, on the free plan, 10 ms of CPU time per request.

Cost is the third axis. AWS states that Local Zone resources are priced differently from the same resources in their parent Region. Red Hat describes the move toward the edge as an increase in the number of distributed locations but a decrease in each location's size, which means many small sites to buy, power and manage.

SimulatorMap a pipeline onto the continuum
  1. T1Image resizePT 8 ms
  2. T2Object detectionPT 40 ms
  3. T3Draw boxesPT 8 ms
150 ms
Network40ms
Response time96ms
Within budget RT 150 ms
τ
network 40 ms · 42%processing 56 ms · 58%

Formula

RT = Σ one-way hops + Σ PT

RT = (5 + 15 + 15 + 5) + (8 + 40 + 8) = 96 ms

Client→Edge 5 · Edge→Fog 15 · Fog→Edge 15 · Edge→Client 5

Each hop costs the difference between the one-way latencies of the two layers: Device 0, Edge 5, Fog 20, Cloud 70 ms from the client.

Recall

What three factors decide where a task is placed, and what is the placement rule?

Latency requirement, processing and storage need, and cost. Place each task on the layer closest to the client that still has enough resources, and forward only what needs more.

Quick check

The lecture places 'running AI models' in the cloud. What is the strongest reason for that placement?

Recap

If you remember nothing else

  • The server side is a continuum: device, mist, near edge, far edge, fog, regional cloud, cloud.
  • Three coarse layers: cloud splits into regions and availability zones, fog into metro nodes and micro data centers, edge into mist, near and far.
  • Proximity and resources pull in opposite directions: the closer the layer, the lower the latency and the smaller the hardware.
  • Latency to the cloud is bounded by physics. Only moving work closer removes propagation delay.
  • Place each task on the closest layer that has enough resources, and forward only what needs more.
  • Real anchors: AWS Wavelength and Local Zones, Cloudflare Workers and Azure Stack Edge (ETSI MEC) at the edge; AWS Regions and availability zones in the cloud.
  • Near and far edge are relative terms. Check the viewpoint.

Sources