SlideShare una empresa de Scribd logo
1 de 55
Descargar para leer sin conexión
Debugging Fastly
VCL: 101
Cassandra Dixon
Solutions Architect | Fastly
Steven Chuob
Technical Account Manager | Fastly
Discussion
● Common Fastly VCL Debugging
● More Technical Fastly VCL
Debugging
Introduction
● Purpose of this training
● What will you learn
● Aiden’s Journey
When Contacting Fastly Support
What to provide:
● Tell us who you are
● Tell us the issue
● Be specific
● Steps to reproduce
● How did you discover it?
Aiden’s Journey
through Fastly
FOR PARTICIPANTS:
ALL CODE IN THIS PRESENTATION IS BROKEN.
DO NOT USE IN PRODUCTION.
Fastly’s Shielding Service
Fastly’s Shielding Service (VCL Flow)
Origin
vcl_recv
vcl_deliver
vcl_fetch
Edge POP Shield POP
vcl_recv
vcl_deliver
vcl_fetch
User
restart
• vcl_recv - This is the first
subroutine the request goes
through
• Handles backend/shield
selections
• Modifications to hostname, url
and other req.headers
vcl_recv
• vcl_fetch - This subroutine runs
after the object has been
fetched from the origin/shield
• Does not run on a hit. Only for
miss, pass requests
• Caching logic and TTLs
vcl_fetch
● vcl_deliver - This is one of the
last subroutine that handles the
response.
● This subroutine sends the object
and its headers to a client
making a request.
● Handles modifications to the
response headers before
delivery
vcl_deliver
● vcl_log - Like vcl_deliver this is
one of the last subroutine to be
run.
● If you configure log, it is called in
this subroutine
vcl_log
• vcl_recv - This is the first subroutine the request goes
through, backend/shield selections happens in this routine.
• vcl_deliver - This is one of the last subroutine that
handles the response from the origin. This subroutine sends
the object and its headers to a client making a request.
• vcl_log - Like vcl_deliver this is one of the last subroutine
to be runned. This will send a log to a logging endpoint
after the request has been handled.
• vcl_error - This subroutine handles any error handling
when the origin responds with an error.
• vcl_miss - This subroutine runs once the object is
determined to not be in cache.
• vcl_hit - This subroutine runs once the object is
determined to be in cache.
• vcl_pass - This subroutine will either be runned after
vcl_recv or vcl_fetch.
• vcl_fetch - This subroutine runs right after the object has
been fetched from the origin and its caching TTL set (based
on what’s being sent from the origin).
Cluster Edge Cluster Node
Clustering
The more you know...
Months 1-6
● Setting up an anonymous cloud
hosting origin
● Enabling Fastly’s Shielding
Service
backend default {
.host = “174.138.66.5”;
.port = “80”;
.connect_timeout = 60s;
.first_byte_timeout = 60s;
.between_bytes_timeout = 60s;
.max_connections = 800;
}
backend shield_ssl_cache_lcyxxxx_LAX {
.is_shield = true;
.connect_timeout = 2s;
.port = "80";
.host = "23.235.47.20";
.max_connections = 1000;
.share_key = "fastlyshield";
} ...
Aiden’s VCL
sub vcl_recv {
# custom vcl set_hostname
# setting host header to match backend
set req.http.host = "hostname expected by origin";
set req.backend = F_addr_xxx;
#do shield here
{ if (req.backend == F_addr_xxx && req.restarts == 0) {
if (server.identity !~ "-LCY$" &&
req.http.Fastly-FF !~ "-LCY") {
set req.backend = ssl_shield_lax_ca_us;}
if (!req.backend.healthy) {
# the shield datacenter is broken so don’t go to it
set req.backend = F_addr_xxx;
}}}
if (req.request != "HEAD" && req.request != "GET" &&
req.request != "FASTLYPURGE") {
return(pass);
}
return(lookup);}
Aiden’s VCL
Aiden’s Testing
● Test URL
● Check Aiden’s VCL
● Testing Tools
○ watch
○ curl
○ Logging
Logging
curl -svo /dev/null
http://altitude-stage.global.ssl.fastly.net/shielding
< HTTP/1.1 200 OK
< Server: Apache/2.4.7 (Ubuntu)
< Content-Type: text/html
< Fastly-Restarts: 1
< Cache-Control: max-age=86400
< Content-Length: 14405
< Accept-Ranges: bytes
< Date: Sun, 18 Jun 2017 16:22:53 GMT
< Via: 1.1 varnish
< Age: 0
< Connection: keep-alive
< X-Served-By: cache-sjc3635-SJC
< X-Cache: MISS
< X-Cache-Hits: 0
< X-Timer: S1497802973.177423,VS0,VE171
< Vary: Accept-Encoding
Test URL
● Hits to Origin multiple times for
the same object
● Fastly-Restart > 0
● Served-By header shows only
one POP
● Age is randomly coming back
as 0.
sub vcl_recv {
# custom vcl set_hostname
# setting host header to match backend
set req.http.host = "hostname expected by origin";
set req.backend = F_addr_xxx;
#do shield here
{ if (req.backend == F_addr_xxx && req.restarts == 0) {
if (server.identity !~ "-LCY$" &&
req.http.Fastly-FF !~ "-LCY") {
set req.backend = ssl_shield_sjc_ca_us;}
if (!req.backend.healthy) {
# the shield datacenter is broken so don’t go to it
set req.backend = F_addr_xxx;
}}}
if (req.request != "HEAD" && req.request != "GET" &&
req.request != "FASTLYPURGE") {
return(pass);
}
return(lookup);}
Reviewing: Aiden’s VCL
Fastly’s Shielding Service (VCL Flow)
Origin
vcl_recv
vcl_deliver
vcl_fetch
Edge POP Shield POP
vcl_recv
vcl_deliver
vcl_fetch
User
restart
http://altitude-stage.global.ssl.fastly.net/req.http.host == altitude-stage.global.ssl.fastly.net
req.url == / vcl_recv
req.http.host == altitude-debug-workshop.dixonkin.com
req.url == /
vcl_recv
Delivers a 500 internal domain not found to the Edge POP
vcl_deliver
vcl_fetch
A restart is triggered due to the 500 error.
Cause: Edge thinks the shield is
unhealthy and thus down
Origin
vcl_deliver
Easiest Solution
# OPTION 1 - Create 2 snippet
# vcl_miss & vcl_pass
## Setting a hostname
if (!req.backend.is_shield) {
set bereq.http.host = "hostname expected by
origin";
}
# OPTION 2 - Create a vcl snippet with
# type “init routine”
# create snippets for vcl_miss & vcl_pass
sub set_hostname {
## Setting a hostname
if (!req.backend.is_shield) {
set bereq.http.host = "hostname expected by
origin";
}
}
Better Solution
# OPTION 2 - Cont’d
# Update Custom VCL file
sub vcl_miss {
#FASTLY miss
call set_hostname;
return(fetch);
}
sub vcl_pass {
#FASTLY pass
call set_hostname;
}
sub vcl_recv {
#FASTLY recv
## Setting a hostname
if (!req.http.Fastly-FF) {
set req.http.host = "hostname expected by origin";
}
if (req.request != "HEAD" && req.request != "GET" && req.request != "FASTLYPURGE") {
return(pass);
}
return(lookup);
}
What about Fastly-FF?
• Aiden creates a login page
• Set Cache-control: max-age=0
• He implemented serving stale
Month 8-10
Fastly Serve Stale
Client
Fastly Origin
Is content cached?
Yes No
Serve Stale Serve Error
Fastly Testing
● Test URL
● Testing Tools
○ watch
○ curl
○ logging
○ Fastly-Debug
curl -svo /dev/null http://altitude-stage.global.ssl.fastly.net/caching/time
< HTTP/1.1 200 OK
< Server: Apache/2.4.7 (Ubuntu)
< Cache-Control: max-age=0, public
< Via: 1.1 varnish
< Content-Length: 1533
< Accept-Ranges: bytes
< Date: Tue, 20 Jun 2017 21:48:21 GMT
< Via: 1.1 varnish
< Age: 8
< Connection: keep-alive
< Fastly-Debug-Digest: 6d34439e4502f525f4dee9255bb9fb1f3b4943b4a9b792c1b07f09f4d31b7c38
< X-Served-By: cache-lax8635-LAX, cache-sjc3640-SJC
< X-Cache: MISS, HIT
< X-Cache-Hits: 0, 1
< X-Timer: S1497995301.171881,VS0,VE0
Test URL
Logging
● Hits in logging
● Cache-Control: max-age=0
● Age is greater than 0.
● Includes log line with a HIT
response
● Includes curl responses;
showing Age=0 and sometimes
Age=6
Aiden’s Support Ticket
Jun 20 14:48:19 Fastly_logs
AltitudeDebugWorkshop-Staging:
2017-06-20T21:48:18+0000 SJC 8.18.217.202 "-" "-"
[20/Jun/2017:21:48:18 +0000] "GET /caching/time
HTTP/1.1" 200 1533 "" "curl/7.48.0"
recv[shield_lax_ca_us:/caching/time] hit
deliver[HIT-STALE:hits=1:age=1] HIT-STALE
sub vcl_recv {
# setting host header to match backend
set req.http.host = "hostname expected by origin";
# Fix encoding issues in urls
set req.url = regsub(req.url, "&amp;", "&");
set req.http.tmpLog = if (req.restarts == 0, "recv", req.http.tmpLog "; recv");
set req.backend = F_addr_xxx;
#do shield here ...
if (req.request != "HEAD" && req.request != "GET" && req.request != "FASTLYPURGE") {
return(pass);
}
# Strip out the service ID for readability
set req.http.tmpLog = req.http.tmpLog "[" regsub(req.backend, "^[a-zA-Z0-9].*--", "") ":"
req.url "]";
return(lookup);
}
Aiden’s VCL - vcl_recv
sub vcl_miss {
set req.http.tmpLog = req.http.tmpLog " miss";
#--FASTLY MISS START
...
# Snippet set_hostname_miss : 100
if (!req.backend.is_shield) {
set bereq.http.host = "altitude-debug-workshop.dixonkin.com";
}
#--FASTLY MISS END
return(fetch);
}
Aiden’s VCL - vcl_miss
sub vcl_fetch {
set beresp.do_stream = true;
#if (beresp.status >= 500 && beresp.status < 600) {
# /* deliver stale if the object is available */
# if (stale.exists) {
# return(deliver);
# }
...
#set stale_if_error and stale_while_revalidate (customize these values)
set beresp.stale_if_error = 86400s;
set beresp.stale_while_revalidate = 10s;
if (req.http.X-Debug) {
set beresp.http.Backend-Name = beresp.backend.name;
}
...
}
Aiden’s VCL - vcl_fetch
● Cache-control: max-age=0 is
not equivalent to a pass object
● TTL of zero is cacheable- serve
stale applies
Aiden: No Regrets,
Lessons Learned
Solutions
OPTION 1 - Update
cache-control header on your
origin
OPTION 2 - Create a cache setting
on Fastly with a condition on the
path
OPTION 3 - Custom VCL in vcl_recv after
the #FASTLY recv macros.
Break
• New Photo Gallery released on
website
• TTL needed for static pictures
• Aiden’s origin is not sending the
cache control header for this
content.
• He adds a cache header on
Fastly
Month 14 -15
sub vcl_fetch {
set beresp.do_stream = true;
...
#set stale_if_error and stale_while_revalidate
(customize these values)
set beresp.stale_if_error = 86400s;
set beresp.stale_while_revalidate = 10s;
if (req.http.X-Debug) {
set beresp.http.Backend-Name =
beresp.backend.name;
}
...
#--FASTLY FETCH BEGIN
...
# priority: 10
if ( req.url == "/redirect1" ) {
# Header rewrite Static Page Cache : 10
set beresp.http.Cache-Control = "max-age=3600";
}
...
}
Aiden’s VCL
Fastly Testing
● Test URL
● Testing Tools
○ watch
○ curl
○ logging
○ Fastly-Debug
curl -svo /dev/null http://altitude-stage.global.ssl.fastly.net/redirect1 -H 'Fastly-Debug:1'
< HTTP/1.1 200 OK
< Server: Apache/2.4.7 (Ubuntu)
< Cache-Control: max-age=3600
< Content-Length: 1917
< Accept-Ranges: bytes
< Date: Wed, 21 Jun 2017 20:24:02 GMT
< Via: 1.1 varnish
< Age: 1
< Connection: keep-alive
< CDN-Process-Log: recv[shield_lax_ca_us:/redirect1] hit deliver[HIT:hits=1:age=1]
< Fastly-Debug-Path: (D cache-sjc3121-SJC 1498076643) (F cache-sjc3121-SJC 1498076642)
< Fastly-Debug-TTL: (H cache-sjc3121-SJC 119.237 86400.000 1)
< Fastly-Debug-Digest: cfb378e8d0413b6345893969c58d8ed23b6db487be9197c0d24d8b5833df8970
< X-Served-By: cache-sjc3121-SJC
< X-Cache: HIT
< X-Cache-Hits: 1
< X-Timer: S1498076643.983655,VS0,VE0
Curl Test
Logging
Wait - What is Fastly-Debug showing?
Fastly-Debug-Path: (D cache-sjc3121-SJC 1498076643) (F cache-sjc3121-SJC
1498076642)
Fastly-Debug-TTL: (H cache-sjc3121-SJC 119.237 86400.000 1)
The first number is the TTL
remaining for the object
The third number is current age
of the item in cache
The second number refers to
the grace
● Object is expiring after 120
seconds
● Fastly-Debug is saying the
object TTL is 120 seconds
sub vcl_fetch {
set beresp.do_stream = true;
...
#set stale_if_error and stale_while_revalidate
(customize these values)
set beresp.stale_if_error = 86400s;
set beresp.stale_while_revalidate = 10s;
...
#FASTLY fetch
...
if (beresp.http.Expires ||
beresp.http.Surrogate-Control ~ "max-age" ||
beresp.http.Cache-Control ~"(s-maxage|max-age)") {
# keep the ttl here
} else if (beresp.cacheable) {
# apply the default ttl
set beresp.ttl = 3701s;
}
}
Aiden’s VCL
Important VCL Logic
TTL Flow
Origin
vcl_recv
vcl_deliver
vcl_fetch
Edge POP Shield POP
vcl_recv
vcl_deliver
vcl_fetch
User
vcl_recv vcl_recv
Origin TTL = 0
TTL = 120
Cache-Control:
max-age=3600
vcl_fetch
vcl_deliver
vcl_fetch
vcl_deliver
TTL = 3600
● There is a default TTL of 120
that is used when the object
has no TTL or Cache-Control
headers from the origin.
● The starting TTL is set before
vcl_fetch runs on a service
Lessons Learned
Solution
A Cache-control header created
in vcl_fetch does not reset the
TTL
To set a TTL, modify the variable
beresp.ttl in vcl_fetch
Therefore create a cache setting on Fastly
to actually change and set the beresp.ttl
• A starting point for Debugging
• Streaming Logs
• Basic understanding on VCL
subroutines
Recap
Questions?
Thank you
Cassandra & Steven

Más contenido relacionado

La actualidad más candente

Design & Performance - Steve Souders at Fastly Altitude 2015
Design & Performance - Steve Souders at Fastly Altitude 2015Design & Performance - Steve Souders at Fastly Altitude 2015
Design & Performance - Steve Souders at Fastly Altitude 2015Fastly
 
Altitude SF 2017: Building a continuous deployment pipeline
Altitude SF 2017: Building a continuous deployment pipelineAltitude SF 2017: Building a continuous deployment pipeline
Altitude SF 2017: Building a continuous deployment pipelineFastly
 
VCL template abstraction model and automated deployments to Fastly
VCL template abstraction model and automated deployments to FastlyVCL template abstraction model and automated deployments to Fastly
VCL template abstraction model and automated deployments to FastlyFastly
 
Caching the Uncacheable: Leveraging Your CDN to Cache Dynamic Content
Caching the Uncacheable: Leveraging Your CDN to Cache Dynamic ContentCaching the Uncacheable: Leveraging Your CDN to Cache Dynamic Content
Caching the Uncacheable: Leveraging Your CDN to Cache Dynamic ContentFastly
 
Altitude SF 2017: Security at the edge
Altitude SF 2017: Security at the edgeAltitude SF 2017: Security at the edge
Altitude SF 2017: Security at the edgeFastly
 
Altitude SF 2017: Optimizing your hit rate
Altitude SF 2017: Optimizing your hit rateAltitude SF 2017: Optimizing your hit rate
Altitude SF 2017: Optimizing your hit rateFastly
 
Altitude SF 2017: Logging at the edge
Altitude SF 2017: Logging at the edgeAltitude SF 2017: Logging at the edge
Altitude SF 2017: Logging at the edgeFastly
 
Stupid Boot Tricks: using ipxe and chef to get to boot management bliss
Stupid Boot Tricks: using ipxe and chef to get to boot management blissStupid Boot Tricks: using ipxe and chef to get to boot management bliss
Stupid Boot Tricks: using ipxe and chef to get to boot management blissmacslide
 
Altitude NY 2018: Programming the edge workshop
Altitude NY 2018: Programming the edge workshopAltitude NY 2018: Programming the edge workshop
Altitude NY 2018: Programming the edge workshopFastly
 
I can't believe it's not a queue: Kafka and Spring
I can't believe it's not a queue: Kafka and SpringI can't believe it's not a queue: Kafka and Spring
I can't believe it's not a queue: Kafka and SpringJoe Kutner
 
Altitude NY 2018: 132 websites, 1 service: Your local news runs on Fastly
Altitude NY 2018: 132 websites, 1 service: Your local news runs on FastlyAltitude NY 2018: 132 websites, 1 service: Your local news runs on Fastly
Altitude NY 2018: 132 websites, 1 service: Your local news runs on FastlyFastly
 
Altitude NY 2018: Leveraging Log Streaming to Build the Best Dashboards, Ever
Altitude NY 2018: Leveraging Log Streaming to Build the Best Dashboards, EverAltitude NY 2018: Leveraging Log Streaming to Build the Best Dashboards, Ever
Altitude NY 2018: Leveraging Log Streaming to Build the Best Dashboards, EverFastly
 
Consul - service discovery and others
Consul - service discovery and othersConsul - service discovery and others
Consul - service discovery and othersWalter Liu
 
Fastly CEO Artur Bergman at Altitude NYC
Fastly CEO Artur Bergman at Altitude NYCFastly CEO Artur Bergman at Altitude NYC
Fastly CEO Artur Bergman at Altitude NYCFastly
 
how to mesure web performance metrics
how to mesure web performance metricshow to mesure web performance metrics
how to mesure web performance metricsMarc Cortinas Val
 
Revisiting HTTP/2
Revisiting HTTP/2Revisiting HTTP/2
Revisiting HTTP/2Fastly
 
PyCon US 2012 - Web Server Bottlenecks and Performance Tuning
PyCon US 2012 - Web Server Bottlenecks and Performance TuningPyCon US 2012 - Web Server Bottlenecks and Performance Tuning
PyCon US 2012 - Web Server Bottlenecks and Performance TuningGraham Dumpleton
 
Web前端性能优化 2014
Web前端性能优化 2014Web前端性能优化 2014
Web前端性能优化 2014Yubei Li
 
Building Scalable Websites with Perl
Building Scalable Websites with PerlBuilding Scalable Websites with Perl
Building Scalable Websites with PerlPerrin Harkins
 
Inside election night at The New York Times | Altitude NYC
Inside election night at The New York Times | Altitude NYCInside election night at The New York Times | Altitude NYC
Inside election night at The New York Times | Altitude NYCFastly
 

La actualidad más candente (20)

Design & Performance - Steve Souders at Fastly Altitude 2015
Design & Performance - Steve Souders at Fastly Altitude 2015Design & Performance - Steve Souders at Fastly Altitude 2015
Design & Performance - Steve Souders at Fastly Altitude 2015
 
Altitude SF 2017: Building a continuous deployment pipeline
Altitude SF 2017: Building a continuous deployment pipelineAltitude SF 2017: Building a continuous deployment pipeline
Altitude SF 2017: Building a continuous deployment pipeline
 
VCL template abstraction model and automated deployments to Fastly
VCL template abstraction model and automated deployments to FastlyVCL template abstraction model and automated deployments to Fastly
VCL template abstraction model and automated deployments to Fastly
 
Caching the Uncacheable: Leveraging Your CDN to Cache Dynamic Content
Caching the Uncacheable: Leveraging Your CDN to Cache Dynamic ContentCaching the Uncacheable: Leveraging Your CDN to Cache Dynamic Content
Caching the Uncacheable: Leveraging Your CDN to Cache Dynamic Content
 
Altitude SF 2017: Security at the edge
Altitude SF 2017: Security at the edgeAltitude SF 2017: Security at the edge
Altitude SF 2017: Security at the edge
 
Altitude SF 2017: Optimizing your hit rate
Altitude SF 2017: Optimizing your hit rateAltitude SF 2017: Optimizing your hit rate
Altitude SF 2017: Optimizing your hit rate
 
Altitude SF 2017: Logging at the edge
Altitude SF 2017: Logging at the edgeAltitude SF 2017: Logging at the edge
Altitude SF 2017: Logging at the edge
 
Stupid Boot Tricks: using ipxe and chef to get to boot management bliss
Stupid Boot Tricks: using ipxe and chef to get to boot management blissStupid Boot Tricks: using ipxe and chef to get to boot management bliss
Stupid Boot Tricks: using ipxe and chef to get to boot management bliss
 
Altitude NY 2018: Programming the edge workshop
Altitude NY 2018: Programming the edge workshopAltitude NY 2018: Programming the edge workshop
Altitude NY 2018: Programming the edge workshop
 
I can't believe it's not a queue: Kafka and Spring
I can't believe it's not a queue: Kafka and SpringI can't believe it's not a queue: Kafka and Spring
I can't believe it's not a queue: Kafka and Spring
 
Altitude NY 2018: 132 websites, 1 service: Your local news runs on Fastly
Altitude NY 2018: 132 websites, 1 service: Your local news runs on FastlyAltitude NY 2018: 132 websites, 1 service: Your local news runs on Fastly
Altitude NY 2018: 132 websites, 1 service: Your local news runs on Fastly
 
Altitude NY 2018: Leveraging Log Streaming to Build the Best Dashboards, Ever
Altitude NY 2018: Leveraging Log Streaming to Build the Best Dashboards, EverAltitude NY 2018: Leveraging Log Streaming to Build the Best Dashboards, Ever
Altitude NY 2018: Leveraging Log Streaming to Build the Best Dashboards, Ever
 
Consul - service discovery and others
Consul - service discovery and othersConsul - service discovery and others
Consul - service discovery and others
 
Fastly CEO Artur Bergman at Altitude NYC
Fastly CEO Artur Bergman at Altitude NYCFastly CEO Artur Bergman at Altitude NYC
Fastly CEO Artur Bergman at Altitude NYC
 
how to mesure web performance metrics
how to mesure web performance metricshow to mesure web performance metrics
how to mesure web performance metrics
 
Revisiting HTTP/2
Revisiting HTTP/2Revisiting HTTP/2
Revisiting HTTP/2
 
PyCon US 2012 - Web Server Bottlenecks and Performance Tuning
PyCon US 2012 - Web Server Bottlenecks and Performance TuningPyCon US 2012 - Web Server Bottlenecks and Performance Tuning
PyCon US 2012 - Web Server Bottlenecks and Performance Tuning
 
Web前端性能优化 2014
Web前端性能优化 2014Web前端性能优化 2014
Web前端性能优化 2014
 
Building Scalable Websites with Perl
Building Scalable Websites with PerlBuilding Scalable Websites with Perl
Building Scalable Websites with Perl
 
Inside election night at The New York Times | Altitude NYC
Inside election night at The New York Times | Altitude NYCInside election night at The New York Times | Altitude NYC
Inside election night at The New York Times | Altitude NYC
 

Similar a Debug Fastly VCL for Optimal Caching and Performance

Varnish presentation for the Symfony Zaragoza user group
Varnish presentation for the Symfony Zaragoza user groupVarnish presentation for the Symfony Zaragoza user group
Varnish presentation for the Symfony Zaragoza user groupJorge Nerín
 
Altitude SF 2017: Advanced VCL: Shielding and Clustering
Altitude SF 2017: Advanced VCL: Shielding and ClusteringAltitude SF 2017: Advanced VCL: Shielding and Clustering
Altitude SF 2017: Advanced VCL: Shielding and ClusteringFastly
 
Altitude San Francisco 2018: Testing with Fastly Workshop
Altitude San Francisco 2018: Testing with Fastly WorkshopAltitude San Francisco 2018: Testing with Fastly Workshop
Altitude San Francisco 2018: Testing with Fastly WorkshopFastly
 
Altitude San Francisco 2018: Programming the Edge
Altitude San Francisco 2018: Programming the EdgeAltitude San Francisco 2018: Programming the Edge
Altitude San Francisco 2018: Programming the EdgeFastly
 
Javascript Everywhere
Javascript EverywhereJavascript Everywhere
Javascript EverywherePascal Rettig
 
Supercharging Content Delivery with Varnish
Supercharging Content Delivery with VarnishSupercharging Content Delivery with Varnish
Supercharging Content Delivery with VarnishSamantha Quiñones
 
Automating Software Development Life Cycle - A DevOps Approach
Automating Software Development Life Cycle - A DevOps ApproachAutomating Software Development Life Cycle - A DevOps Approach
Automating Software Development Life Cycle - A DevOps ApproachAkshaya Mahapatra
 
Salesforce at Stacki Atlanta Meetup February 2016
Salesforce at Stacki Atlanta Meetup February 2016Salesforce at Stacki Atlanta Meetup February 2016
Salesforce at Stacki Atlanta Meetup February 2016StackIQ
 
Small Python Tools for Software Release Engineering
Small Python Tools for Software Release EngineeringSmall Python Tools for Software Release Engineering
Small Python Tools for Software Release Engineeringpycontw
 
Installation Openstack Swift
Installation Openstack SwiftInstallation Openstack Swift
Installation Openstack Swiftymtech
 
Real World Lessons on the Pain Points of Node.js Applications
Real World Lessons on the Pain Points of Node.js ApplicationsReal World Lessons on the Pain Points of Node.js Applications
Real World Lessons on the Pain Points of Node.js ApplicationsBen Hall
 
"Load Testing Distributed Systems with NBomber 4.0", Anton Moldovan
"Load Testing Distributed Systems with NBomber 4.0",  Anton Moldovan"Load Testing Distributed Systems with NBomber 4.0",  Anton Moldovan
"Load Testing Distributed Systems with NBomber 4.0", Anton MoldovanFwdays
 
One commit, one release. Continuously delivering a Symfony project.
One commit, one release. Continuously delivering a Symfony project.One commit, one release. Continuously delivering a Symfony project.
One commit, one release. Continuously delivering a Symfony project.Javier López
 
Ch10.애플리케이션 서버의 병목_발견_방법
Ch10.애플리케이션 서버의 병목_발견_방법Ch10.애플리케이션 서버의 병목_발견_방법
Ch10.애플리케이션 서버의 병목_발견_방법Minchul Jung
 
Debugging: Rules And Tools - PHPTek 11 Version
Debugging: Rules And Tools - PHPTek 11 VersionDebugging: Rules And Tools - PHPTek 11 Version
Debugging: Rules And Tools - PHPTek 11 VersionIan Barber
 
How we use and deploy Varnish at Opera
How we use and deploy Varnish at OperaHow we use and deploy Varnish at Opera
How we use and deploy Varnish at OperaCosimo Streppone
 
Making Symofny shine with Varnish - SymfonyCon Madrid 2014
Making Symofny shine with Varnish - SymfonyCon Madrid 2014Making Symofny shine with Varnish - SymfonyCon Madrid 2014
Making Symofny shine with Varnish - SymfonyCon Madrid 2014Barel Barelon
 

Similar a Debug Fastly VCL for Optimal Caching and Performance (20)

Varnish presentation for the Symfony Zaragoza user group
Varnish presentation for the Symfony Zaragoza user groupVarnish presentation for the Symfony Zaragoza user group
Varnish presentation for the Symfony Zaragoza user group
 
Altitude SF 2017: Advanced VCL: Shielding and Clustering
Altitude SF 2017: Advanced VCL: Shielding and ClusteringAltitude SF 2017: Advanced VCL: Shielding and Clustering
Altitude SF 2017: Advanced VCL: Shielding and Clustering
 
Altitude San Francisco 2018: Testing with Fastly Workshop
Altitude San Francisco 2018: Testing with Fastly WorkshopAltitude San Francisco 2018: Testing with Fastly Workshop
Altitude San Francisco 2018: Testing with Fastly Workshop
 
Run Node Run
Run Node RunRun Node Run
Run Node Run
 
Varnish
VarnishVarnish
Varnish
 
Altitude San Francisco 2018: Programming the Edge
Altitude San Francisco 2018: Programming the EdgeAltitude San Francisco 2018: Programming the Edge
Altitude San Francisco 2018: Programming the Edge
 
Javascript Everywhere
Javascript EverywhereJavascript Everywhere
Javascript Everywhere
 
Supercharging Content Delivery with Varnish
Supercharging Content Delivery with VarnishSupercharging Content Delivery with Varnish
Supercharging Content Delivery with Varnish
 
Automating Software Development Life Cycle - A DevOps Approach
Automating Software Development Life Cycle - A DevOps ApproachAutomating Software Development Life Cycle - A DevOps Approach
Automating Software Development Life Cycle - A DevOps Approach
 
Salesforce at Stacki Atlanta Meetup February 2016
Salesforce at Stacki Atlanta Meetup February 2016Salesforce at Stacki Atlanta Meetup February 2016
Salesforce at Stacki Atlanta Meetup February 2016
 
Small Python Tools for Software Release Engineering
Small Python Tools for Software Release EngineeringSmall Python Tools for Software Release Engineering
Small Python Tools for Software Release Engineering
 
Installation Openstack Swift
Installation Openstack SwiftInstallation Openstack Swift
Installation Openstack Swift
 
Real World Lessons on the Pain Points of Node.js Applications
Real World Lessons on the Pain Points of Node.js ApplicationsReal World Lessons on the Pain Points of Node.js Applications
Real World Lessons on the Pain Points of Node.js Applications
 
"Load Testing Distributed Systems with NBomber 4.0", Anton Moldovan
"Load Testing Distributed Systems with NBomber 4.0",  Anton Moldovan"Load Testing Distributed Systems with NBomber 4.0",  Anton Moldovan
"Load Testing Distributed Systems with NBomber 4.0", Anton Moldovan
 
AB testing
AB testingAB testing
AB testing
 
One commit, one release. Continuously delivering a Symfony project.
One commit, one release. Continuously delivering a Symfony project.One commit, one release. Continuously delivering a Symfony project.
One commit, one release. Continuously delivering a Symfony project.
 
Ch10.애플리케이션 서버의 병목_발견_방법
Ch10.애플리케이션 서버의 병목_발견_방법Ch10.애플리케이션 서버의 병목_발견_방법
Ch10.애플리케이션 서버의 병목_발견_방법
 
Debugging: Rules And Tools - PHPTek 11 Version
Debugging: Rules And Tools - PHPTek 11 VersionDebugging: Rules And Tools - PHPTek 11 Version
Debugging: Rules And Tools - PHPTek 11 Version
 
How we use and deploy Varnish at Opera
How we use and deploy Varnish at OperaHow we use and deploy Varnish at Opera
How we use and deploy Varnish at Opera
 
Making Symofny shine with Varnish - SymfonyCon Madrid 2014
Making Symofny shine with Varnish - SymfonyCon Madrid 2014Making Symofny shine with Varnish - SymfonyCon Madrid 2014
Making Symofny shine with Varnish - SymfonyCon Madrid 2014
 

Más de Fastly

Altitude San Francisco 2018: Preparing for Video Streaming Events at Scale
Altitude San Francisco 2018: Preparing for Video Streaming Events at ScaleAltitude San Francisco 2018: Preparing for Video Streaming Events at Scale
Altitude San Francisco 2018: Preparing for Video Streaming Events at ScaleFastly
 
Altitude San Francisco 2018: Building the Souther Hemisphere of the Internet
Altitude San Francisco 2018: Building the Souther Hemisphere of the InternetAltitude San Francisco 2018: Building the Souther Hemisphere of the Internet
Altitude San Francisco 2018: Building the Souther Hemisphere of the InternetFastly
 
Altitude San Francisco 2018: The World Cup Stream
Altitude San Francisco 2018: The World Cup StreamAltitude San Francisco 2018: The World Cup Stream
Altitude San Francisco 2018: The World Cup StreamFastly
 
Altitude San Francisco 2018: We Own Our Destiny
Altitude San Francisco 2018: We Own Our DestinyAltitude San Francisco 2018: We Own Our Destiny
Altitude San Francisco 2018: We Own Our DestinyFastly
 
Altitude San Francisco 2018: Scale and Stability at the Edge with 1.4 Billion...
Altitude San Francisco 2018: Scale and Stability at the Edge with 1.4 Billion...Altitude San Francisco 2018: Scale and Stability at the Edge with 1.4 Billion...
Altitude San Francisco 2018: Scale and Stability at the Edge with 1.4 Billion...Fastly
 
Altitude San Francisco 2018: Moving Off the Monolith: A Seamless Migration
Altitude San Francisco 2018: Moving Off the Monolith: A Seamless MigrationAltitude San Francisco 2018: Moving Off the Monolith: A Seamless Migration
Altitude San Francisco 2018: Moving Off the Monolith: A Seamless MigrationFastly
 
Altitude San Francisco 2018: Bringing TLS to GitHub Pages
Altitude San Francisco 2018: Bringing TLS to GitHub PagesAltitude San Francisco 2018: Bringing TLS to GitHub Pages
Altitude San Francisco 2018: Bringing TLS to GitHub PagesFastly
 
Altitude San Francisco 2018: HTTP Invalidation Workshop
Altitude San Francisco 2018: HTTP Invalidation WorkshopAltitude San Francisco 2018: HTTP Invalidation Workshop
Altitude San Francisco 2018: HTTP Invalidation WorkshopFastly
 
Altitude San Francisco 2018: HTTP/2 Tales: Discovery and Woe
Altitude San Francisco 2018: HTTP/2 Tales: Discovery and WoeAltitude San Francisco 2018: HTTP/2 Tales: Discovery and Woe
Altitude San Francisco 2018: HTTP/2 Tales: Discovery and WoeFastly
 
Altitude San Francisco 2018: How Magento moved to the cloud while maintaining...
Altitude San Francisco 2018: How Magento moved to the cloud while maintaining...Altitude San Francisco 2018: How Magento moved to the cloud while maintaining...
Altitude San Francisco 2018: How Magento moved to the cloud while maintaining...Fastly
 
Altitude San Francisco 2018: Scaling Ethereum to 10B requests per day
Altitude San Francisco 2018: Scaling Ethereum to 10B requests per dayAltitude San Francisco 2018: Scaling Ethereum to 10B requests per day
Altitude San Francisco 2018: Scaling Ethereum to 10B requests per dayFastly
 
Altitude San Francisco 2018: Authentication at the Edge
Altitude San Francisco 2018: Authentication at the EdgeAltitude San Francisco 2018: Authentication at the Edge
Altitude San Francisco 2018: Authentication at the EdgeFastly
 
Altitude San Francisco 2018: WebAssembly Tools & Applications
Altitude San Francisco 2018: WebAssembly Tools & ApplicationsAltitude San Francisco 2018: WebAssembly Tools & Applications
Altitude San Francisco 2018: WebAssembly Tools & ApplicationsFastly
 
Altitude San Francisco 2018: Fastly Purge Control at the USA TODAY NETWORK
Altitude San Francisco 2018: Fastly Purge Control at the USA TODAY NETWORKAltitude San Francisco 2018: Fastly Purge Control at the USA TODAY NETWORK
Altitude San Francisco 2018: Fastly Purge Control at the USA TODAY NETWORKFastly
 
Altitude San Francisco 2018: WAF Workshop
Altitude San Francisco 2018: WAF WorkshopAltitude San Francisco 2018: WAF Workshop
Altitude San Francisco 2018: WAF WorkshopFastly
 
Altitude San Francisco 2018: Logging at the Edge
Altitude San Francisco 2018: Logging at the Edge Altitude San Francisco 2018: Logging at the Edge
Altitude San Francisco 2018: Logging at the Edge Fastly
 
Altitude San Francisco 2018: Video Workshop Docs
Altitude San Francisco 2018: Video Workshop DocsAltitude San Francisco 2018: Video Workshop Docs
Altitude San Francisco 2018: Video Workshop DocsFastly
 
Enabling lightning fast content delivery for Spotify
Enabling lightning fast content delivery for SpotifyEnabling lightning fast content delivery for Spotify
Enabling lightning fast content delivery for SpotifyFastly
 
What's next in edge computing?
What's next in edge computing?What's next in edge computing?
What's next in edge computing?Fastly
 
Honing headers for highly hardened highspeed hypertext
Honing headers for highly hardened highspeed hypertextHoning headers for highly hardened highspeed hypertext
Honing headers for highly hardened highspeed hypertextFastly
 

Más de Fastly (20)

Altitude San Francisco 2018: Preparing for Video Streaming Events at Scale
Altitude San Francisco 2018: Preparing for Video Streaming Events at ScaleAltitude San Francisco 2018: Preparing for Video Streaming Events at Scale
Altitude San Francisco 2018: Preparing for Video Streaming Events at Scale
 
Altitude San Francisco 2018: Building the Souther Hemisphere of the Internet
Altitude San Francisco 2018: Building the Souther Hemisphere of the InternetAltitude San Francisco 2018: Building the Souther Hemisphere of the Internet
Altitude San Francisco 2018: Building the Souther Hemisphere of the Internet
 
Altitude San Francisco 2018: The World Cup Stream
Altitude San Francisco 2018: The World Cup StreamAltitude San Francisco 2018: The World Cup Stream
Altitude San Francisco 2018: The World Cup Stream
 
Altitude San Francisco 2018: We Own Our Destiny
Altitude San Francisco 2018: We Own Our DestinyAltitude San Francisco 2018: We Own Our Destiny
Altitude San Francisco 2018: We Own Our Destiny
 
Altitude San Francisco 2018: Scale and Stability at the Edge with 1.4 Billion...
Altitude San Francisco 2018: Scale and Stability at the Edge with 1.4 Billion...Altitude San Francisco 2018: Scale and Stability at the Edge with 1.4 Billion...
Altitude San Francisco 2018: Scale and Stability at the Edge with 1.4 Billion...
 
Altitude San Francisco 2018: Moving Off the Monolith: A Seamless Migration
Altitude San Francisco 2018: Moving Off the Monolith: A Seamless MigrationAltitude San Francisco 2018: Moving Off the Monolith: A Seamless Migration
Altitude San Francisco 2018: Moving Off the Monolith: A Seamless Migration
 
Altitude San Francisco 2018: Bringing TLS to GitHub Pages
Altitude San Francisco 2018: Bringing TLS to GitHub PagesAltitude San Francisco 2018: Bringing TLS to GitHub Pages
Altitude San Francisco 2018: Bringing TLS to GitHub Pages
 
Altitude San Francisco 2018: HTTP Invalidation Workshop
Altitude San Francisco 2018: HTTP Invalidation WorkshopAltitude San Francisco 2018: HTTP Invalidation Workshop
Altitude San Francisco 2018: HTTP Invalidation Workshop
 
Altitude San Francisco 2018: HTTP/2 Tales: Discovery and Woe
Altitude San Francisco 2018: HTTP/2 Tales: Discovery and WoeAltitude San Francisco 2018: HTTP/2 Tales: Discovery and Woe
Altitude San Francisco 2018: HTTP/2 Tales: Discovery and Woe
 
Altitude San Francisco 2018: How Magento moved to the cloud while maintaining...
Altitude San Francisco 2018: How Magento moved to the cloud while maintaining...Altitude San Francisco 2018: How Magento moved to the cloud while maintaining...
Altitude San Francisco 2018: How Magento moved to the cloud while maintaining...
 
Altitude San Francisco 2018: Scaling Ethereum to 10B requests per day
Altitude San Francisco 2018: Scaling Ethereum to 10B requests per dayAltitude San Francisco 2018: Scaling Ethereum to 10B requests per day
Altitude San Francisco 2018: Scaling Ethereum to 10B requests per day
 
Altitude San Francisco 2018: Authentication at the Edge
Altitude San Francisco 2018: Authentication at the EdgeAltitude San Francisco 2018: Authentication at the Edge
Altitude San Francisco 2018: Authentication at the Edge
 
Altitude San Francisco 2018: WebAssembly Tools & Applications
Altitude San Francisco 2018: WebAssembly Tools & ApplicationsAltitude San Francisco 2018: WebAssembly Tools & Applications
Altitude San Francisco 2018: WebAssembly Tools & Applications
 
Altitude San Francisco 2018: Fastly Purge Control at the USA TODAY NETWORK
Altitude San Francisco 2018: Fastly Purge Control at the USA TODAY NETWORKAltitude San Francisco 2018: Fastly Purge Control at the USA TODAY NETWORK
Altitude San Francisco 2018: Fastly Purge Control at the USA TODAY NETWORK
 
Altitude San Francisco 2018: WAF Workshop
Altitude San Francisco 2018: WAF WorkshopAltitude San Francisco 2018: WAF Workshop
Altitude San Francisco 2018: WAF Workshop
 
Altitude San Francisco 2018: Logging at the Edge
Altitude San Francisco 2018: Logging at the Edge Altitude San Francisco 2018: Logging at the Edge
Altitude San Francisco 2018: Logging at the Edge
 
Altitude San Francisco 2018: Video Workshop Docs
Altitude San Francisco 2018: Video Workshop DocsAltitude San Francisco 2018: Video Workshop Docs
Altitude San Francisco 2018: Video Workshop Docs
 
Enabling lightning fast content delivery for Spotify
Enabling lightning fast content delivery for SpotifyEnabling lightning fast content delivery for Spotify
Enabling lightning fast content delivery for Spotify
 
What's next in edge computing?
What's next in edge computing?What's next in edge computing?
What's next in edge computing?
 
Honing headers for highly hardened highspeed hypertext
Honing headers for highly hardened highspeed hypertextHoning headers for highly hardened highspeed hypertext
Honing headers for highly hardened highspeed hypertext
 

Último

The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilV3cube
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 

Último (20)

The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 

Debug Fastly VCL for Optimal Caching and Performance

  • 1. Debugging Fastly VCL: 101 Cassandra Dixon Solutions Architect | Fastly Steven Chuob Technical Account Manager | Fastly
  • 2. Discussion ● Common Fastly VCL Debugging ● More Technical Fastly VCL Debugging
  • 3. Introduction ● Purpose of this training ● What will you learn ● Aiden’s Journey
  • 4. When Contacting Fastly Support What to provide: ● Tell us who you are ● Tell us the issue ● Be specific ● Steps to reproduce ● How did you discover it?
  • 5.
  • 7. FOR PARTICIPANTS: ALL CODE IN THIS PRESENTATION IS BROKEN. DO NOT USE IN PRODUCTION.
  • 9. Fastly’s Shielding Service (VCL Flow) Origin vcl_recv vcl_deliver vcl_fetch Edge POP Shield POP vcl_recv vcl_deliver vcl_fetch User restart
  • 10. • vcl_recv - This is the first subroutine the request goes through • Handles backend/shield selections • Modifications to hostname, url and other req.headers vcl_recv
  • 11. • vcl_fetch - This subroutine runs after the object has been fetched from the origin/shield • Does not run on a hit. Only for miss, pass requests • Caching logic and TTLs vcl_fetch
  • 12. ● vcl_deliver - This is one of the last subroutine that handles the response. ● This subroutine sends the object and its headers to a client making a request. ● Handles modifications to the response headers before delivery vcl_deliver
  • 13. ● vcl_log - Like vcl_deliver this is one of the last subroutine to be run. ● If you configure log, it is called in this subroutine vcl_log
  • 14. • vcl_recv - This is the first subroutine the request goes through, backend/shield selections happens in this routine. • vcl_deliver - This is one of the last subroutine that handles the response from the origin. This subroutine sends the object and its headers to a client making a request. • vcl_log - Like vcl_deliver this is one of the last subroutine to be runned. This will send a log to a logging endpoint after the request has been handled. • vcl_error - This subroutine handles any error handling when the origin responds with an error. • vcl_miss - This subroutine runs once the object is determined to not be in cache. • vcl_hit - This subroutine runs once the object is determined to be in cache. • vcl_pass - This subroutine will either be runned after vcl_recv or vcl_fetch. • vcl_fetch - This subroutine runs right after the object has been fetched from the origin and its caching TTL set (based on what’s being sent from the origin). Cluster Edge Cluster Node
  • 16. The more you know...
  • 17. Months 1-6 ● Setting up an anonymous cloud hosting origin ● Enabling Fastly’s Shielding Service
  • 18. backend default { .host = “174.138.66.5”; .port = “80”; .connect_timeout = 60s; .first_byte_timeout = 60s; .between_bytes_timeout = 60s; .max_connections = 800; } backend shield_ssl_cache_lcyxxxx_LAX { .is_shield = true; .connect_timeout = 2s; .port = "80"; .host = "23.235.47.20"; .max_connections = 1000; .share_key = "fastlyshield"; } ... Aiden’s VCL
  • 19. sub vcl_recv { # custom vcl set_hostname # setting host header to match backend set req.http.host = "hostname expected by origin"; set req.backend = F_addr_xxx; #do shield here { if (req.backend == F_addr_xxx && req.restarts == 0) { if (server.identity !~ "-LCY$" && req.http.Fastly-FF !~ "-LCY") { set req.backend = ssl_shield_lax_ca_us;} if (!req.backend.healthy) { # the shield datacenter is broken so don’t go to it set req.backend = F_addr_xxx; }}} if (req.request != "HEAD" && req.request != "GET" && req.request != "FASTLYPURGE") { return(pass); } return(lookup);} Aiden’s VCL
  • 20. Aiden’s Testing ● Test URL ● Check Aiden’s VCL ● Testing Tools ○ watch ○ curl ○ Logging
  • 22. curl -svo /dev/null http://altitude-stage.global.ssl.fastly.net/shielding < HTTP/1.1 200 OK < Server: Apache/2.4.7 (Ubuntu) < Content-Type: text/html < Fastly-Restarts: 1 < Cache-Control: max-age=86400 < Content-Length: 14405 < Accept-Ranges: bytes < Date: Sun, 18 Jun 2017 16:22:53 GMT < Via: 1.1 varnish < Age: 0 < Connection: keep-alive < X-Served-By: cache-sjc3635-SJC < X-Cache: MISS < X-Cache-Hits: 0 < X-Timer: S1497802973.177423,VS0,VE171 < Vary: Accept-Encoding Test URL
  • 23. ● Hits to Origin multiple times for the same object ● Fastly-Restart > 0 ● Served-By header shows only one POP ● Age is randomly coming back as 0.
  • 24. sub vcl_recv { # custom vcl set_hostname # setting host header to match backend set req.http.host = "hostname expected by origin"; set req.backend = F_addr_xxx; #do shield here { if (req.backend == F_addr_xxx && req.restarts == 0) { if (server.identity !~ "-LCY$" && req.http.Fastly-FF !~ "-LCY") { set req.backend = ssl_shield_sjc_ca_us;} if (!req.backend.healthy) { # the shield datacenter is broken so don’t go to it set req.backend = F_addr_xxx; }}} if (req.request != "HEAD" && req.request != "GET" && req.request != "FASTLYPURGE") { return(pass); } return(lookup);} Reviewing: Aiden’s VCL
  • 25. Fastly’s Shielding Service (VCL Flow) Origin vcl_recv vcl_deliver vcl_fetch Edge POP Shield POP vcl_recv vcl_deliver vcl_fetch User restart http://altitude-stage.global.ssl.fastly.net/req.http.host == altitude-stage.global.ssl.fastly.net req.url == / vcl_recv req.http.host == altitude-debug-workshop.dixonkin.com req.url == / vcl_recv Delivers a 500 internal domain not found to the Edge POP vcl_deliver vcl_fetch A restart is triggered due to the 500 error. Cause: Edge thinks the shield is unhealthy and thus down Origin vcl_deliver
  • 27. # OPTION 1 - Create 2 snippet # vcl_miss & vcl_pass ## Setting a hostname if (!req.backend.is_shield) { set bereq.http.host = "hostname expected by origin"; } # OPTION 2 - Create a vcl snippet with # type “init routine” # create snippets for vcl_miss & vcl_pass sub set_hostname { ## Setting a hostname if (!req.backend.is_shield) { set bereq.http.host = "hostname expected by origin"; } } Better Solution # OPTION 2 - Cont’d # Update Custom VCL file sub vcl_miss { #FASTLY miss call set_hostname; return(fetch); } sub vcl_pass { #FASTLY pass call set_hostname; }
  • 28. sub vcl_recv { #FASTLY recv ## Setting a hostname if (!req.http.Fastly-FF) { set req.http.host = "hostname expected by origin"; } if (req.request != "HEAD" && req.request != "GET" && req.request != "FASTLYPURGE") { return(pass); } return(lookup); } What about Fastly-FF?
  • 29. • Aiden creates a login page • Set Cache-control: max-age=0 • He implemented serving stale Month 8-10
  • 30. Fastly Serve Stale Client Fastly Origin Is content cached? Yes No Serve Stale Serve Error
  • 31. Fastly Testing ● Test URL ● Testing Tools ○ watch ○ curl ○ logging ○ Fastly-Debug
  • 32. curl -svo /dev/null http://altitude-stage.global.ssl.fastly.net/caching/time < HTTP/1.1 200 OK < Server: Apache/2.4.7 (Ubuntu) < Cache-Control: max-age=0, public < Via: 1.1 varnish < Content-Length: 1533 < Accept-Ranges: bytes < Date: Tue, 20 Jun 2017 21:48:21 GMT < Via: 1.1 varnish < Age: 8 < Connection: keep-alive < Fastly-Debug-Digest: 6d34439e4502f525f4dee9255bb9fb1f3b4943b4a9b792c1b07f09f4d31b7c38 < X-Served-By: cache-lax8635-LAX, cache-sjc3640-SJC < X-Cache: MISS, HIT < X-Cache-Hits: 0, 1 < X-Timer: S1497995301.171881,VS0,VE0 Test URL
  • 34. ● Hits in logging ● Cache-Control: max-age=0 ● Age is greater than 0.
  • 35. ● Includes log line with a HIT response ● Includes curl responses; showing Age=0 and sometimes Age=6 Aiden’s Support Ticket Jun 20 14:48:19 Fastly_logs AltitudeDebugWorkshop-Staging: 2017-06-20T21:48:18+0000 SJC 8.18.217.202 "-" "-" [20/Jun/2017:21:48:18 +0000] "GET /caching/time HTTP/1.1" 200 1533 "" "curl/7.48.0" recv[shield_lax_ca_us:/caching/time] hit deliver[HIT-STALE:hits=1:age=1] HIT-STALE
  • 36. sub vcl_recv { # setting host header to match backend set req.http.host = "hostname expected by origin"; # Fix encoding issues in urls set req.url = regsub(req.url, "&amp;", "&"); set req.http.tmpLog = if (req.restarts == 0, "recv", req.http.tmpLog "; recv"); set req.backend = F_addr_xxx; #do shield here ... if (req.request != "HEAD" && req.request != "GET" && req.request != "FASTLYPURGE") { return(pass); } # Strip out the service ID for readability set req.http.tmpLog = req.http.tmpLog "[" regsub(req.backend, "^[a-zA-Z0-9].*--", "") ":" req.url "]"; return(lookup); } Aiden’s VCL - vcl_recv
  • 37. sub vcl_miss { set req.http.tmpLog = req.http.tmpLog " miss"; #--FASTLY MISS START ... # Snippet set_hostname_miss : 100 if (!req.backend.is_shield) { set bereq.http.host = "altitude-debug-workshop.dixonkin.com"; } #--FASTLY MISS END return(fetch); } Aiden’s VCL - vcl_miss
  • 38. sub vcl_fetch { set beresp.do_stream = true; #if (beresp.status >= 500 && beresp.status < 600) { # /* deliver stale if the object is available */ # if (stale.exists) { # return(deliver); # } ... #set stale_if_error and stale_while_revalidate (customize these values) set beresp.stale_if_error = 86400s; set beresp.stale_while_revalidate = 10s; if (req.http.X-Debug) { set beresp.http.Backend-Name = beresp.backend.name; } ... } Aiden’s VCL - vcl_fetch
  • 39. ● Cache-control: max-age=0 is not equivalent to a pass object ● TTL of zero is cacheable- serve stale applies Aiden: No Regrets, Lessons Learned
  • 40. Solutions OPTION 1 - Update cache-control header on your origin OPTION 2 - Create a cache setting on Fastly with a condition on the path OPTION 3 - Custom VCL in vcl_recv after the #FASTLY recv macros.
  • 41. Break
  • 42. • New Photo Gallery released on website • TTL needed for static pictures • Aiden’s origin is not sending the cache control header for this content. • He adds a cache header on Fastly Month 14 -15
  • 43. sub vcl_fetch { set beresp.do_stream = true; ... #set stale_if_error and stale_while_revalidate (customize these values) set beresp.stale_if_error = 86400s; set beresp.stale_while_revalidate = 10s; if (req.http.X-Debug) { set beresp.http.Backend-Name = beresp.backend.name; } ... #--FASTLY FETCH BEGIN ... # priority: 10 if ( req.url == "/redirect1" ) { # Header rewrite Static Page Cache : 10 set beresp.http.Cache-Control = "max-age=3600"; } ... } Aiden’s VCL
  • 44. Fastly Testing ● Test URL ● Testing Tools ○ watch ○ curl ○ logging ○ Fastly-Debug
  • 45. curl -svo /dev/null http://altitude-stage.global.ssl.fastly.net/redirect1 -H 'Fastly-Debug:1' < HTTP/1.1 200 OK < Server: Apache/2.4.7 (Ubuntu) < Cache-Control: max-age=3600 < Content-Length: 1917 < Accept-Ranges: bytes < Date: Wed, 21 Jun 2017 20:24:02 GMT < Via: 1.1 varnish < Age: 1 < Connection: keep-alive < CDN-Process-Log: recv[shield_lax_ca_us:/redirect1] hit deliver[HIT:hits=1:age=1] < Fastly-Debug-Path: (D cache-sjc3121-SJC 1498076643) (F cache-sjc3121-SJC 1498076642) < Fastly-Debug-TTL: (H cache-sjc3121-SJC 119.237 86400.000 1) < Fastly-Debug-Digest: cfb378e8d0413b6345893969c58d8ed23b6db487be9197c0d24d8b5833df8970 < X-Served-By: cache-sjc3121-SJC < X-Cache: HIT < X-Cache-Hits: 1 < X-Timer: S1498076643.983655,VS0,VE0 Curl Test
  • 47. Wait - What is Fastly-Debug showing? Fastly-Debug-Path: (D cache-sjc3121-SJC 1498076643) (F cache-sjc3121-SJC 1498076642) Fastly-Debug-TTL: (H cache-sjc3121-SJC 119.237 86400.000 1) The first number is the TTL remaining for the object The third number is current age of the item in cache The second number refers to the grace
  • 48. ● Object is expiring after 120 seconds ● Fastly-Debug is saying the object TTL is 120 seconds
  • 49. sub vcl_fetch { set beresp.do_stream = true; ... #set stale_if_error and stale_while_revalidate (customize these values) set beresp.stale_if_error = 86400s; set beresp.stale_while_revalidate = 10s; ... #FASTLY fetch ... if (beresp.http.Expires || beresp.http.Surrogate-Control ~ "max-age" || beresp.http.Cache-Control ~"(s-maxage|max-age)") { # keep the ttl here } else if (beresp.cacheable) { # apply the default ttl set beresp.ttl = 3701s; } } Aiden’s VCL Important VCL Logic
  • 50. TTL Flow Origin vcl_recv vcl_deliver vcl_fetch Edge POP Shield POP vcl_recv vcl_deliver vcl_fetch User vcl_recv vcl_recv Origin TTL = 0 TTL = 120 Cache-Control: max-age=3600 vcl_fetch vcl_deliver vcl_fetch vcl_deliver TTL = 3600
  • 51. ● There is a default TTL of 120 that is used when the object has no TTL or Cache-Control headers from the origin. ● The starting TTL is set before vcl_fetch runs on a service Lessons Learned
  • 52. Solution A Cache-control header created in vcl_fetch does not reset the TTL To set a TTL, modify the variable beresp.ttl in vcl_fetch Therefore create a cache setting on Fastly to actually change and set the beresp.ttl
  • 53. • A starting point for Debugging • Streaming Logs • Basic understanding on VCL subroutines Recap