SlideShare a Scribd company logo
1 of 21
Download to read offline
Automating
tasks with
VARNISH PLUS
Hugo Cruz
Product Manager
About me
• Oslo based developer, from Portugal
• Lots of hats, mostly Front-end
Email: hugo@varnish-software.com
IRC: hugo on irc.linpro.no
Twitter: @hrcru
AGENDA
- Automating tasks with VARNISH PLUS
• The Varnish Plus minimum stack
• Playing with statistics
• VCL version control with Git
• Cache invalidation
• Increase value with VCS
Live demo
ahead
Besides black magic, there is only
automation and mechanisation
- Federico Garcia Lorca
Monitoring Configuration
Business
Statistics
Automate your tasks
Integrate Varnish Plus in your
existing toolset.
The minimum
value stack
BenefitsSetup
Management tools
Realtime monitoring
JSON API for everything
$ Setup Varnish Plus repository
$ Install Varnish Cache Plus
$ Install varnish-agent and vcs-probe
$ Install Varnish Administration Console
$ Install Varnish Custom Statistics
Varnish Cache Plus
Supercharged
version of the
popular open source
HTTP reverse proxy,
Varnish Cache
Varnish
Administration
Console
Cluster controller
for you Varnish(s)
installation
Varnish Custom
Statistics
A real-time
statistics engine
Varnish agents
and VCS probe
Varnish agent and
VCS probe are
responsible for
extracting data for
VAC and VCS
Minimal Value stack
VAC
VCS
4.1
VCS probe
Varnish agent
Varnish Cache Plus
4.1
VCS probe
Varnish agent
4.0
VCS probe
Varnish agent
4.0
VCS probe
Varnish agent
{
UI
API
UI
API
Varnish
Customs Statistics
Varnish
Administration Console
Playing with
stats
Different aggregations available
RRD statistical data
gathered in the VAC
Completely configurable
Varnish Stats through
VAC
More VCL fun
3. automatic deploy and rollover.
1. setup a git hook with VAC API
2. change VCL
VCL + GIT
Purging
Benefits
high performance purging
$ curl -X PURGE -H ‘X-Cache-Group: Production’
-H ‘X-HMAC:
0xf7bc83f430538424b13298e6aa6fb143ef4d59a14946175997479dbc2d1a3cd8
‘ -H ‘X-Timestamp: 1391641007 http://vac-server:8088/purge-url
purge several instances
in a group, fast
$ “ No need for extra setup. Purger is up and running with VAC, on port 8088.”
Issue a purge
acl purgers {
“127.0.0.1”;
“192.168.0.0”/24;
}
sub vcl_recv {
if (req.request == “PURGE”) {
if (!client.ip ~ purgers) {
error 405 “Method not allowed”;
}
if (digest.hmac_sha256(“secret-key”,req.url +
req.http.x-timestamp + req.http.x-cache-group) != req.http.x-hmac) {
error 405 “Method not allowed”;
}
return (lookup);
}
}
Extra security
Super Fast Purger
Fully secure
Increase
value with
VCS
Benefits
Live Production
debugging
Business indicators
Realtime statistics engine
sub vcl_deliver {
# This creates a grouping for each specific value of the Host request
std.log("vcs-key: " + req.http.host);
# This creates a key based on both the Host header and the URL
std.log("vcs-key: URL-“ + req.http.host + req.url);
# This will create two keys 'MISS' and 'HIT', each counting
# stats for requests matching one of the two conditions.
if (obj.hits == 0) {
std.log("vcs-key: MISS");
}
else {
std.log("vcs-key: HIT");
}
}
Time series API
VCS
Basic setup
(counting hits and misses)
A/B testing
Minimum stack
Setup the components
Playing with
stats
VAC powered
Varnish stats
VCL version control
Integrating VCL and GIT
Cache Invalidation
Using the Super Fast Purger
VCS in production
Debugging with VCS
Summing up
Thank you!
Reach out to me if you have further questions
hugo@varnish-software.com

More Related Content

Similar to Setting up automated tasks

Caching with Varnish
Caching with VarnishCaching with Varnish
Caching with Varnish
schoefmax
 
T3DD12 Caching with Varnish
T3DD12 Caching with VarnishT3DD12 Caching with Varnish
T3DD12 Caching with Varnish
AOE
 
VMware VI Toolkit UKVMUG
VMware VI Toolkit UKVMUGVMware VI Toolkit UKVMUG
VMware VI Toolkit UKVMUG
Alan Renouf
 
Php through the eyes of a hoster phpbnl11
Php through the eyes of a hoster phpbnl11Php through the eyes of a hoster phpbnl11
Php through the eyes of a hoster phpbnl11
Combell NV
 

Similar to Setting up automated tasks (20)

Varnish qconsp 2011
Varnish qconsp 2011Varnish qconsp 2011
Varnish qconsp 2011
 
Advanced cache invalidation
Advanced cache invalidationAdvanced cache invalidation
Advanced cache invalidation
 
PHP Project development with Vagrant
PHP Project development with VagrantPHP Project development with Vagrant
PHP Project development with Vagrant
 
Caching with Varnish
Caching with VarnishCaching with Varnish
Caching with Varnish
 
Running php on nginx
Running php on nginxRunning php on nginx
Running php on nginx
 
Varnish and Drupal- Accelerating Website Performance and Flexibility with Var...
Varnish and Drupal- Accelerating Website Performance and Flexibility with Var...Varnish and Drupal- Accelerating Website Performance and Flexibility with Var...
Varnish and Drupal- Accelerating Website Performance and Flexibility with Var...
 
Professional deployment
Professional deploymentProfessional deployment
Professional deployment
 
Performance
PerformancePerformance
Performance
 
Google App Engine: For PHP Developers
Google App Engine: For PHP DevelopersGoogle App Engine: For PHP Developers
Google App Engine: For PHP Developers
 
AMS Node Meetup December presentation Phusion Passenger
AMS Node Meetup December presentation Phusion PassengerAMS Node Meetup December presentation Phusion Passenger
AMS Node Meetup December presentation Phusion Passenger
 
Monitoring Docker at Scale - Docker San Francisco Meetup - August 11, 2015
Monitoring Docker at Scale - Docker San Francisco Meetup - August 11, 2015Monitoring Docker at Scale - Docker San Francisco Meetup - August 11, 2015
Monitoring Docker at Scale - Docker San Francisco Meetup - August 11, 2015
 
HAProxy scale out using open source
HAProxy scale out using open sourceHAProxy scale out using open source
HAProxy scale out using open source
 
VUG5: Varnish at Opera Software
VUG5: Varnish at Opera SoftwareVUG5: Varnish at Opera Software
VUG5: Varnish at Opera Software
 
T3DD12 Caching with Varnish
T3DD12 Caching with VarnishT3DD12 Caching with Varnish
T3DD12 Caching with Varnish
 
VMware VI Toolkit UKVMUG
VMware VI Toolkit UKVMUGVMware VI Toolkit UKVMUG
VMware VI Toolkit UKVMUG
 
My Opera meets Varnish, Dec 2009
My Opera meets Varnish, Dec 2009My Opera meets Varnish, Dec 2009
My Opera meets Varnish, Dec 2009
 
Load Balancing and Scaling with NGINX
Load Balancing and Scaling with NGINXLoad Balancing and Scaling with NGINX
Load Balancing and Scaling with NGINX
 
Varnish Cache Plus. Random notes for wise web developers
Varnish Cache Plus. Random notes for wise web developersVarnish Cache Plus. Random notes for wise web developers
Varnish Cache Plus. Random notes for wise web developers
 
Php through the eyes of a hoster phpbnl11
Php through the eyes of a hoster phpbnl11Php through the eyes of a hoster phpbnl11
Php through the eyes of a hoster phpbnl11
 
Sucuri Webinar: Leveraging Sucuri's API
Sucuri Webinar: Leveraging Sucuri's APISucuri Webinar: Leveraging Sucuri's API
Sucuri Webinar: Leveraging Sucuri's API
 

More from Varnish Software

More from Varnish Software (20)

Ask Me Anything on authentication & authorisation in Varnish
Ask Me Anything on authentication & authorisation in VarnishAsk Me Anything on authentication & authorisation in Varnish
Ask Me Anything on authentication & authorisation in Varnish
 
Boozt.com Use Case
Boozt.com Use CaseBoozt.com Use Case
Boozt.com Use Case
 
Akamai connector for varnish
Akamai connector for varnishAkamai connector for varnish
Akamai connector for varnish
 
Varnish High Availability
Varnish High AvailabilityVarnish High Availability
Varnish High Availability
 
PostNord: Copy On Write
PostNord: Copy On WritePostNord: Copy On Write
PostNord: Copy On Write
 
Varnish extend
Varnish extendVarnish extend
Varnish extend
 
Streaming with Varnish
Streaming with VarnishStreaming with Varnish
Streaming with Varnish
 
Edgestash
EdgestashEdgestash
Edgestash
 
What is new in varnish plus
What is new in varnish plusWhat is new in varnish plus
What is new in varnish plus
 
Varnish Extend demo
Varnish Extend demoVarnish Extend demo
Varnish Extend demo
 
Varnish extend introduction
Varnish extend introductionVarnish extend introduction
Varnish extend introduction
 
Cedexis introduction
Cedexis introductionCedexis introduction
Cedexis introduction
 
Secure content caching
Secure content cachingSecure content caching
Secure content caching
 
Microservices
MicroservicesMicroservices
Microservices
 
Varnishtest
VarnishtestVarnishtest
Varnishtest
 
Lightning fast with Varnish
Lightning fast with VarnishLightning fast with Varnish
Lightning fast with Varnish
 
E-commerce use case
E-commerce use caseE-commerce use case
E-commerce use case
 
Access control
Access controlAccess control
Access control
 
Varnish TLS
Varnish TLSVarnish TLS
Varnish TLS
 
MSE
MSEMSE
MSE
 

Recently uploaded

Tales from a Passkey Provider Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider  Progress from Awareness to Implementation.pptxTales from a Passkey Provider  Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider Progress from Awareness to Implementation.pptx
FIDO Alliance
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc
 

Recently uploaded (20)

Tales from a Passkey Provider Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider  Progress from Awareness to Implementation.pptxTales from a Passkey Provider  Progress from Awareness to Implementation.pptx
Tales from a Passkey Provider Progress from Awareness to Implementation.pptx
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
UiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overviewUiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overview
 
Design and Development of a Provenance Capture Platform for Data Science
Design and Development of a Provenance Capture Platform for Data ScienceDesign and Development of a Provenance Capture Platform for Data Science
Design and Development of a Provenance Capture Platform for Data Science
 
Top 10 CodeIgniter Development Companies
Top 10 CodeIgniter Development CompaniesTop 10 CodeIgniter Development Companies
Top 10 CodeIgniter Development Companies
 
Stronger Together: Developing an Organizational Strategy for Accessible Desig...
Stronger Together: Developing an Organizational Strategy for Accessible Desig...Stronger Together: Developing an Organizational Strategy for Accessible Desig...
Stronger Together: Developing an Organizational Strategy for Accessible Desig...
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
ChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps ProductivityChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps Productivity
 
Design Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptxDesign Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptx
 
Choreo: Empowering the Future of Enterprise Software Engineering
Choreo: Empowering the Future of Enterprise Software EngineeringChoreo: Empowering the Future of Enterprise Software Engineering
Choreo: Empowering the Future of Enterprise Software Engineering
 
Navigating Identity and Access Management in the Modern Enterprise
Navigating Identity and Access Management in the Modern EnterpriseNavigating Identity and Access Management in the Modern Enterprise
Navigating Identity and Access Management in the Modern Enterprise
 
TEST BANK For Principles of Anatomy and Physiology, 16th Edition by Gerard J....
TEST BANK For Principles of Anatomy and Physiology, 16th Edition by Gerard J....TEST BANK For Principles of Anatomy and Physiology, 16th Edition by Gerard J....
TEST BANK For Principles of Anatomy and Physiology, 16th Edition by Gerard J....
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
ADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptxADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptx
 
Intro to Passkeys and the State of Passwordless.pptx
Intro to Passkeys and the State of Passwordless.pptxIntro to Passkeys and the State of Passwordless.pptx
Intro to Passkeys and the State of Passwordless.pptx
 

Setting up automated tasks

  • 1.
  • 3. Hugo Cruz Product Manager About me • Oslo based developer, from Portugal • Lots of hats, mostly Front-end Email: hugo@varnish-software.com IRC: hugo on irc.linpro.no Twitter: @hrcru
  • 4. AGENDA - Automating tasks with VARNISH PLUS • The Varnish Plus minimum stack • Playing with statistics • VCL version control with Git • Cache invalidation • Increase value with VCS
  • 6. Besides black magic, there is only automation and mechanisation - Federico Garcia Lorca
  • 7. Monitoring Configuration Business Statistics Automate your tasks Integrate Varnish Plus in your existing toolset.
  • 9. BenefitsSetup Management tools Realtime monitoring JSON API for everything $ Setup Varnish Plus repository $ Install Varnish Cache Plus $ Install varnish-agent and vcs-probe $ Install Varnish Administration Console $ Install Varnish Custom Statistics
  • 10. Varnish Cache Plus Supercharged version of the popular open source HTTP reverse proxy, Varnish Cache Varnish Administration Console Cluster controller for you Varnish(s) installation Varnish Custom Statistics A real-time statistics engine Varnish agents and VCS probe Varnish agent and VCS probe are responsible for extracting data for VAC and VCS Minimal Value stack
  • 11. VAC VCS 4.1 VCS probe Varnish agent Varnish Cache Plus 4.1 VCS probe Varnish agent 4.0 VCS probe Varnish agent 4.0 VCS probe Varnish agent { UI API UI API Varnish Customs Statistics Varnish Administration Console
  • 13. Different aggregations available RRD statistical data gathered in the VAC Completely configurable Varnish Stats through VAC
  • 15. 3. automatic deploy and rollover. 1. setup a git hook with VAC API 2. change VCL VCL + GIT
  • 17. Benefits high performance purging $ curl -X PURGE -H ‘X-Cache-Group: Production’ -H ‘X-HMAC: 0xf7bc83f430538424b13298e6aa6fb143ef4d59a14946175997479dbc2d1a3cd8 ‘ -H ‘X-Timestamp: 1391641007 http://vac-server:8088/purge-url purge several instances in a group, fast $ “ No need for extra setup. Purger is up and running with VAC, on port 8088.” Issue a purge acl purgers { “127.0.0.1”; “192.168.0.0”/24; } sub vcl_recv { if (req.request == “PURGE”) { if (!client.ip ~ purgers) { error 405 “Method not allowed”; } if (digest.hmac_sha256(“secret-key”,req.url + req.http.x-timestamp + req.http.x-cache-group) != req.http.x-hmac) { error 405 “Method not allowed”; } return (lookup); } } Extra security Super Fast Purger Fully secure
  • 19. Benefits Live Production debugging Business indicators Realtime statistics engine sub vcl_deliver { # This creates a grouping for each specific value of the Host request std.log("vcs-key: " + req.http.host); # This creates a key based on both the Host header and the URL std.log("vcs-key: URL-“ + req.http.host + req.url); # This will create two keys 'MISS' and 'HIT', each counting # stats for requests matching one of the two conditions. if (obj.hits == 0) { std.log("vcs-key: MISS"); } else { std.log("vcs-key: HIT"); } } Time series API VCS Basic setup (counting hits and misses) A/B testing
  • 20. Minimum stack Setup the components Playing with stats VAC powered Varnish stats VCL version control Integrating VCL and GIT Cache Invalidation Using the Super Fast Purger VCS in production Debugging with VCS Summing up
  • 21. Thank you! Reach out to me if you have further questions hugo@varnish-software.com