Cloudflare Cache Reserve Walkthrough and Demo
Q & A
What is the primary focus of the video presented by Humir Ahmed?
-The video focuses on Cloudflare's Cash Reserve feature, including a brief discussion on the basics of Cloudflare CDN and a demo of Cash Reserve.
How can users onboard onto Cloudflare CDN?
-Users can onboard by clicking 'add site' on the dashboard, entering their domain, and Cloudflare will automatically import DNS records. Users are then given Cloudflare name servers to change their authoritative DNS.
What is the alternative to changing the primary authoritative DNS for using Cloudflare CDN?
-Users can still use Cloudflare CDN without changing their primary authoritative DNS by doing a partial CNAME setup.
What happens when an HTTP request matches a cachable file extension in Cloudflare CDN?
-If the request matches a cachable extension, Cloudflare serves the resource from cache if present. Otherwise, it fetches from the origin to fill the cache and then serves the response to the client.
What is Cloudflare's Tiered Cache and how does it function?
-Cloudflare's Tiered Cache divides its global data centers into upper and lower tiers. Only upper tiers request content from the origin, distributing it to lower tiers, thereby improving bandwidth efficiency and reducing origin load.
What triggers a cache miss in Cloudflare CDN?
-A cache miss occurs due to intentional actions like cache TTL expiration or content purging, or unintentional actions like purging based on the Least Recently Used (LRU) algorithm.
What is Cloudflare's Cash Reserve, and how does it enhance cache hit ratio?
-Cloudflare's Cash Reserve stores all cachable files in persistent object storage buckets. It acts as an ultimate upper tier, checking storage buckets before going to the origin during a cache miss, thereby increasing cache hit ratio.
How does Cash Reserve impact traffic flow and origin server load?
-Cash Reserve minimizes the need to pull content from the origin by checking storage buckets during a cache miss, reducing unnecessary egress fees and decreasing load on the origin server.
How did the Cash Reserve feature affect the cache hit ratio in the demo?
-After enabling Cash Reserve, the cache hit ratio improved significantly, reaching over 90% from a previous 80%, moving closer to a 100% cache hit ratio.
How can users manage and monitor their use of Cloudflare's Cash Reserve?
-Users can view data stored in Cash Reserve, aggregate storage used, and read/write operations from the Cloudflare dashboard. They can also pause Cash Reserve, purge cache content, and create page rules for specific caching behaviors.
Mindmap
Highlights
Introduction to Cloudflare Cash Reserve with a brief overview of Cloudflare CDN basics.
Easy onboarding process onto Cloudflare CDN described.
Explanation of the basic traffic flow in Cloudflare CDN, including cacheable file extension matching.
Introduction of Cloudflare's Tiered Cache and its benefits like improved bandwidth efficiency.
Explanation of how Cloudflare's Smart Tiered Cache Topology works for content distribution.
Discussion on cache misses scenarios and their causes.
Introduction of Cloudflare Cash Reserve to increase cache hit ratio by storing all cacheable files.
Details on how Cash Reserve acts as an ultimate upper tier in Cloudflare's caching strategy.
Demonstration setup explained with a large image and video gallery hosted on a third-party cloud.
Cloudflare dashboard walkthrough showing Cash Reserve features and stats.
Explanation of Cash Reserve's role in improving cache hit ratio from 80% to over 90%.
Insight into Cloudflare's caching details, including most popular content types.
Page rules creation for more granular caching behavior control.
Overview of cash rules for overriding TTL settings directly at the edge.
Demonstration of log push setup and including the Cash Reserve used field for better visibility.
Transcripts
hello my name is humir Ahmed and in this
video I'm going to walk through Cloud
for cash reserve and follow up with demo
I will very briefly discuss some Basics
from cloud for CDN before getting right
into Cash Reserve to provide a better
grasp of how everything fits together
however I'll keep this very minimal so I
can focus on cash Reserve for more
thorough understanding of cloud
vercidian in general and how it works
please see the cloud for CDN reference
architecture in the prior video I did on
cloudflare CDN walkthrough with that
let's get going
first let's talk about how easily you
can get started and onboarded onto
cloudflare CDN
from the dashboard simply click add site
and enter your domain cloud4 can
automatically import your DNS records
from your existing DNS provider and
finally you're given Cloud for name
servers you can use to change your
authoritative DNS so here you're using
cloudford's DNS Azure authoritative DNS
and also onboarded onto cloudflare CDN
now if you don't want to change your
primary or authoritative DNS you can
still use cloudflare CDN by simply doing
a partial cname setup so lots of
flexibility there
so if we look at the very basics of the
traffic flow now first HTTP request is
made closest data center to user handles
the request users HTTP request URL is
matched against the list of cachable
file extensions if the request matches
an extension on the list Cloud first
serves the resource from Cache if
present
second content is fetched from Cache or
origin cloudflare examines its caches in
multiple Network locations for content
and serves it if present if the content
is still in Quad verse cache cloudfare
attempts to revalidate the content with
the origin before serving the response
to the client if the resource is not
present in the cache Cloud Fair requests
the resource from the origin to fill the
cache and the response is then sent to
the client who initiated the request
if cachable content is cached on the
response so cloudflare's cash logic
examines the HTTP response received from
the origin the response is either deemed
cachable and written to disk for use
with the next request for the same
resource or the request is deemed
uncashable
now let's take a look at the traffic
flow with Cloud Fair tiered cache with
smart tiered cache topology enabled as a
reminder tiered cash divides
cloudflare's network of global data
centers into a hierarchy of upper tiers
and lower tiers and in order to control
bandwidth number of connections between
an origin and cloudflare only upper
tiers are permitted to request content
from an origin and are responsible for
Distributing information to the lower
tiers smart tiered cash topology is the
default topology and available for free
for all plans this is also recommended
for most deployments instructing
cloudflare to find the single best upper
tiers for your Origins
benefits here include improved bandwidth
efficiency reduced origin load and
making websites more cost effective to
operate
so when client one sends a request to
the closest data center data center one
here
if the content is not cached the upper
tier data center label data center 3
here is checked if the content is not
cached at the upper tier the upper tier
requests the content from the origin
once their sponsors returned from the
origin the upper tier caches it and
returns a response to the lower tier
which also caches it and returns a
response to the client
now let's say client 2 makes the same
request for the same content to its
closest data center data center too
if the content is not cached to Data
Center too similar to Prior the upper
tier data center is checked however in
this case content was requested prior
via client 1 and the upper tier data
center has the content cached and
Returns the cache content to the lower
tier data center data center 2 which in
turn caches the content and responds
back to the client decreasing latency
saving bandwidth and load on the server
and providing better overall performance
so now that we have a better
understanding of cloud for CDN when does
a cache Miss occur well we have two
scenarios first intentional cash TTL
expired or content purged customers set
cache control time to signify when the
content is out of date and needs to be
revalidated once expired content needs
to be revalidated and may need to be
pulled from the origin if updated
version exists customers can Purge
content manually at any time
second unintentional cloudflare Purge
content due to lru or least recently
used algorithm to optimize storage less
frequently accessed content may be
purged based on lru or how long the
network wants content to remain cached
now this is where Cloud for cash Reserve
can be useful to further increase cash
hit ratio by automatically storing all
cachable files into cloudflare's
persistent object storage buckets
basically cash Reserve acts like an
ultimate upper tier and when there's a
cash Miss cloudflare will first check
these storage buckets before going to
the origin you can see here I've enabled
it and I'll walk through this more in
the demo
so let's look at the traffic flow now
again when the client sends a request to
the lower tier data center if the
content is not cached the upper tier
data center is checked this time however
if the content is not cached at the
upper tier the upper tier checks cash
Reserve instead of requesting straight
from the origin
if the content is not present in cash
Reserve cash Reserve will request it
from the origin once response is
returned from the origin cash Reserve
caches the content while replying to the
upper tier which also caches it and
Returns the response to the lower tier
which also caches it and responds to the
client now next time the same content is
requested if there is a cache Miss at
the lower tier data center the upper
tier data center is checked now if
there's say cache missed at the upper
tier data center let's say expired TTL
or content has been evicted cash Reserve
will be checked and if content exists at
Cash reserve it will be returned and
cached at the upper tier before being
returned and cashed at the lower tier
and returned to the client so you can
see here how cash Reserve acts as the
ultimate upper tier and minimizes the
need to pull from the origin decreasing
unnecessary egress fees
with that let's jump into the demo for
demonstration purposes I deployed a site
here that's basically a large image and
video gallery for uploading and
downloading content
now again for demonstration purposes the
website is actually hosted on a
third-party Cloud I also have automated
traffic running to simulate visitors
accessing the site
so now I'm going to go over and head
over to my cloudflare dashboard and here
you can see I have cash Reserve enabled
and it shows the current amount of data
stored in cash Reserve as well as the
total aggregate storage used over the
specific time period and you also have a
view of total cash Reserve read and
write operations once enabled cash
Reserve will start caching files with a
retention period of 30 days which will
be reset on any hits
customers can also pause using cash
Reserve meaning cloudflare's network
will no longer use cash Reserve to serve
data
here under overview you can see the
overall cash status including content
served by cloudflare and content served
by the origin
you can see the vast majority of
requests are served by cloudflare and if
you scroll down here and hover over the
cast status you can see a
92.96 cash hit ratio really good now
since I just enabled cash reserve a few
days ago if I go up here instead of 24
hours I select previous 30 days
we could see the cash hit ratio was
lower at around 80 percent so cash
Reserve really helped get into that 90
plus ratio getting us closer and closer
to that hundred percent
and scrolling down here you can see more
overall caching details in general like
the most popular content types and what
specific content is the most popular
here on the left you can also Purge the
cache which will also Purge content and
cash reserves you can also create page
rules to get more granular on any
specific caching behavior let's go into
this and take a look in more detail you
can see I created a page rule matching
on all requests that contain this
specific domain name
and I set the cache level to Cache
everything that's cachable but also can
select different cash level including
bypassing cache if desired
so now I'm gonna head over to caching
and look at Cash rules
so under cash rules I can also create a
rule as I did here to override ttls from
Cache control headers
this is done right at the edge and you
can see here if I click into it
all requests to this hostname
I've configured as content eligible for
caching and overridden the origin TTL
setting it to 12 hours with cloudflare
httl it makes it very convenient to set
TTL in one place for all assets
now I'm going to head over to analytics
and logs there
and I'll go under logs you can see I've
set up a log push I'm just going to
click edit here
last thing I want to show here is you
can also log data to external logs and
include the cash Reserve used field to
get more visibility into requests and
respective content being served from
cash Reserve I hope you found this
cloudflare cash Reserve walkthrough in
demo informational and useful for
additional details make sure to check
out the cloudflare cash Reserve product
page
Browse More Related Video
PHP 8 MySQL Project on Online Doctor Appointment Booking System
Cloudflare Workers Crash Course | Deploy Your Website with Cloudflare
How to host your Webflow/Framer site with CMS for FREE on Cloudflare. No code required
How to deploy your websites to Cloudflare's Pages Platform for free
Build an AI Workforce 🤖💬🤖 Multiple Conversable Agents
Introduction to Cache Memory
⛅ Cloudflare Workers as a Web Server (with Webpack) #serverless (lesson 2)
5.0 / 5 (0 votes)