SlideShare a Scribd company logo
1 of 17
The Secret Life of CQ Dispatcher
Venu Gummadala
What is a Dispatcher?
➲ A load balancing &
➲ A caching tool
Dispatcher – A Load Balancer
CQ1CQ1CQ1 CQ3CQ2
Web server
Dispatcher
Client
Dispatcher – A Caching Tool
CQ
Web server
Dispatcher
Client
Dynamic Content
Remote Content
Static Content
Why Use It ?
➲ As a load balancer prevents system from
crashing by distributing requests among cq
server instances.
➲ As a caching tool improves performance by
serving static content locally from your web
server.
But …
➲ You can also use it behind a physical load
balancer.
➲ You can also use it for a single CQ
instance.
➲ It is also valid for both Author & Publisher
environments.
But .. why not CDNs?
*should not be compared with CDNs … really
➲ CDNs are also caching tools
➲ CDNs serve digital assets from a
geographical location near to you
➲ CDN is a implemented using a Provider
➲ Dispatcher is OTB and made for CQ
more than a CDN
➲ By serving static content from Web server
process it reduces load on CQ server
➲ By enforcing rules it filters un-wanted traffic
at the web server level itself
➲ By re-writing urls it protects CQ from
hackers realizing the content paths
➲ By blocking url patterns, headers ensures
added protection & system failure.
more than a CDN... Continued
➲ Gives the ability to include SSIs before
request goes to CQ instance
➲ Improves User Experience on the site by
responding quickly when serving static
content
➲ Finally .. gives more control how you mange
(delete or retain) cached files
➲ Just a module and a config file to be used
on a web server
➲ Usually obtained from daycare
➲ Supported web servers :-
Apache Web Server – 2.0, 2.2 & 2.4
Microsoft IIS – 7.0, 7.5 & 8.0
& Oracle iPlanet Web server – 7.0
➲ Instructions to install
dev.day.com/install
How to install?
How to configure?
➲ Edit your dispatcher.any file using any Editor.
➲ Sample dispatcher code structure..
/website
{
/clientheaders
{
}
/virtualhosts
{
}
/sessionmanagement
{
}
/renders
{
}
/filter
{
}
/cache
{
/rules
{
}
➲ * preconfigured sample file here
/cache
  {
   /docroot "/opt/dispatcher/cache"
   /statfile  "/tmp/dispatcher-website.stat"          
  /allowAuthorized "0"
  /rules
  {
   /0000  { /glob "*" /type "allow" }
   /0001  { /glob "/en/news/*" /type "deny" }
   /0002  { /glob "*/private/*" /type "deny"  }   
  }
➲ What is cached ?
Ans: Everything (specified by '*' and 'allow') 
➲ What is not cached? ( Or what not to cache ? )
Ans: Content under /en/news path & url containing private path
➲ Why ? 
Ans: news can be a feed getting constant updates 
     private can be personalization or profile data
➲ What is docroot?
Ans: location on your webserver where cached content is saved
➲ What is a statfile?
Ans: A file that manages the register of the last time the content was updated
➲ What is allowAuthorized?
Ans: A flag to indicate if auth header, auth cookie & login-token cookie can b
cached  
What is Cached ?
& what is not ?
What is not Cached …
➲ Urls without file extensions
e.g. /content/en is not cached
➲ Urls with query string parameters
e.g. /content/en/blog/recipe.html?user='amy' is not cached
➲ HTTP 'post' method
➲ HTTP response status != '200 OK'
➲ Header response with
'Dispatcher: no-cache'
What is Cached ? ... Continued
& what is not ?
Dispatcher As a Security Tool
➲ Use filter to allow/deny actions & 
access to paths/content/tools 
 
Example
/filter {
 /0001 { /type "deny" /method "POST" /url "/etc/*" }
 /0002 { /type "allow" /method "GET" /url "/etc/*" /query "a=*" }
 /0003 { /type "deny"  /glob "GET *.infinity.json*" }
 /0004 { /type "allow" /glob "* *.js *"    }  # enable javascript
 /0005
    {
    /glob "* /publish/libs/cq/workflow/content/console/archive*"
    /type "deny"
   }
}
0001: Deny all POST methods
0002: Allow GET methods with query parameter = a
0003: Prevent json content dumps
0004: Allow javascript resource files 
0005: Deny access to protected areas & tools .. workflow console in this case. 
Dispatcher As a Security Tool
 
➲ Use virtualhosts for
● Domain mapping
● Re-write urls etc.
➲
Example
/virtualhosts
      {
      "www.isoap.com"
      }
    /renders
      {
      /hostname "internal.isoap.com"
      /port "4503"
      }
Appendix
➲ What is static content ?
Content which may remain un-changed for a specific amount of
time. For e.g. images, scripts, error pages etc.
➲ What is Dynamic Content?
Content which may change with time such as a Sports Score
Card, User Blogs, News etc.
More ?
➲ dev.day.com/more
➲ Even more ?
➲ How to configure a publisher environment ?
➲ Even more performance tweaks ?
➲ Deployment landscape & process ?
➲ For commercial implementations
Contact: Venu.Gummadala@gmail.com
Thank you ...

More Related Content

What's hot

Linux Container Technology 101
Linux Container Technology 101Linux Container Technology 101
Linux Container Technology 101
inside-BigData.com
 
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
Amazon Web Services Korea
 

What's hot (20)

Infrastructure as Code on AWS
Infrastructure as Code on AWSInfrastructure as Code on AWS
Infrastructure as Code on AWS
 
Learn nginx in 90mins
Learn nginx in 90minsLearn nginx in 90mins
Learn nginx in 90mins
 
도커 무작정 따라하기: 도커가 처음인 사람도 60분이면 웹 서버를 올릴 수 있습니다!
도커 무작정 따라하기: 도커가 처음인 사람도 60분이면 웹 서버를 올릴 수 있습니다!도커 무작정 따라하기: 도커가 처음인 사람도 60분이면 웹 서버를 올릴 수 있습니다!
도커 무작정 따라하기: 도커가 처음인 사람도 60분이면 웹 서버를 올릴 수 있습니다!
 
ProxySQL on Kubernetes
ProxySQL on KubernetesProxySQL on Kubernetes
ProxySQL on Kubernetes
 
(DVO308) Docker & ECS in Production: How We Migrated Our Infrastructure from ...
(DVO308) Docker & ECS in Production: How We Migrated Our Infrastructure from ...(DVO308) Docker & ECS in Production: How We Migrated Our Infrastructure from ...
(DVO308) Docker & ECS in Production: How We Migrated Our Infrastructure from ...
 
Azure AKS
Azure AKSAzure AKS
Azure AKS
 
디지털 해적들로부터 영상 콘텐츠 보호하기 – 황윤상 AWS 솔루션즈 아키텍트, 김준호 잉카엔트웍스 매니저:: AWS Cloud Week ...
디지털 해적들로부터 영상 콘텐츠 보호하기 –  황윤상 AWS 솔루션즈 아키텍트, 김준호 잉카엔트웍스 매니저:: AWS Cloud Week ...디지털 해적들로부터 영상 콘텐츠 보호하기 –  황윤상 AWS 솔루션즈 아키텍트, 김준호 잉카엔트웍스 매니저:: AWS Cloud Week ...
디지털 해적들로부터 영상 콘텐츠 보호하기 – 황윤상 AWS 솔루션즈 아키텍트, 김준호 잉카엔트웍스 매니저:: AWS Cloud Week ...
 
[AWSKRUG 컨테이너 소모임] Rancher 기본 입문
[AWSKRUG 컨테이너 소모임] Rancher 기본 입문[AWSKRUG 컨테이너 소모임] Rancher 기본 입문
[AWSKRUG 컨테이너 소모임] Rancher 기본 입문
 
Packer
Packer Packer
Packer
 
Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교
Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교
Amazon DocumentDB vs MongoDB 의 내부 아키텍쳐 와 장단점 비교
 
Linux Container Technology 101
Linux Container Technology 101Linux Container Technology 101
Linux Container Technology 101
 
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container DayECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
 
Docker Networking - Common Issues and Troubleshooting Techniques
Docker Networking - Common Issues and Troubleshooting TechniquesDocker Networking - Common Issues and Troubleshooting Techniques
Docker Networking - Common Issues and Troubleshooting Techniques
 
Red Hat Ansible 적용 사례
Red Hat Ansible 적용 사례Red Hat Ansible 적용 사례
Red Hat Ansible 적용 사례
 
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
 
Amazon OpenSearch Deep dive - 내부구조, 성능최적화 그리고 스케일링
Amazon OpenSearch Deep dive - 내부구조, 성능최적화 그리고 스케일링Amazon OpenSearch Deep dive - 내부구조, 성능최적화 그리고 스케일링
Amazon OpenSearch Deep dive - 내부구조, 성능최적화 그리고 스케일링
 
AWS Lambda 내부 동작 방식 및 활용 방법 자세히 살펴 보기 - 김일호 솔루션즈 아키텍트 매니저, AWS :: AWS Summit ...
AWS Lambda 내부 동작 방식 및 활용 방법 자세히 살펴 보기 - 김일호 솔루션즈 아키텍트 매니저, AWS :: AWS Summit ...AWS Lambda 내부 동작 방식 및 활용 방법 자세히 살펴 보기 - 김일호 솔루션즈 아키텍트 매니저, AWS :: AWS Summit ...
AWS Lambda 내부 동작 방식 및 활용 방법 자세히 살펴 보기 - 김일호 솔루션즈 아키텍트 매니저, AWS :: AWS Summit ...
 
Ansible
AnsibleAnsible
Ansible
 
High Availability Application Architectures in Amazon VPC (ARC202) | AWS re:I...
High Availability Application Architectures in Amazon VPC (ARC202) | AWS re:I...High Availability Application Architectures in Amazon VPC (ARC202) | AWS re:I...
High Availability Application Architectures in Amazon VPC (ARC202) | AWS re:I...
 
Postgres MVCC - A Developer Centric View of Multi Version Concurrency Control
Postgres MVCC - A Developer Centric View of Multi Version Concurrency ControlPostgres MVCC - A Developer Centric View of Multi Version Concurrency Control
Postgres MVCC - A Developer Centric View of Multi Version Concurrency Control
 

Viewers also liked

Dispatcher Oom
Dispatcher OomDispatcher Oom
Dispatcher Oom
day
 

Viewers also liked (7)

AEM (CQ) Dispatcher Caching Webinar 2013
AEM (CQ) Dispatcher Caching Webinar 2013AEM (CQ) Dispatcher Caching Webinar 2013
AEM (CQ) Dispatcher Caching Webinar 2013
 
Aem dispatcher – tips & tricks
Aem dispatcher – tips & tricksAem dispatcher – tips & tricks
Aem dispatcher – tips & tricks
 
AEM (CQ) Dispatcher Security and CDN+Browser Caching
AEM (CQ) Dispatcher Security and CDN+Browser CachingAEM (CQ) Dispatcher Security and CDN+Browser Caching
AEM (CQ) Dispatcher Security and CDN+Browser Caching
 
The six key steps to AEM architecture
The six key steps to AEM architectureThe six key steps to AEM architecture
The six key steps to AEM architecture
 
Dispatcher Oom
Dispatcher OomDispatcher Oom
Dispatcher Oom
 
User Interface customization for AEM 6
User Interface customization for AEM 6User Interface customization for AEM 6
User Interface customization for AEM 6
 
Apache Server Tutorial
Apache Server TutorialApache Server Tutorial
Apache Server Tutorial
 

Similar to The secret life of a dispatcher (Adobe CQ AEM)

Cloud computing 3702
Cloud computing 3702Cloud computing 3702
Cloud computing 3702
Jess Coburn
 
WSO2 Dep Sync for Artifact Synchronization of Cluster Nodes
WSO2 Dep Sync for Artifact Synchronization of Cluster NodesWSO2 Dep Sync for Artifact Synchronization of Cluster Nodes
WSO2 Dep Sync for Artifact Synchronization of Cluster Nodes
WSO2
 
[WSO2] Deployment Synchronizer for Deployment Artifact Synchronization Betwee...
[WSO2] Deployment Synchronizer for Deployment Artifact Synchronization Betwee...[WSO2] Deployment Synchronizer for Deployment Artifact Synchronization Betwee...
[WSO2] Deployment Synchronizer for Deployment Artifact Synchronization Betwee...
Kasun Gajasinghe
 
SharePoint Disaster Recovery to Microsoft Azure
SharePoint Disaster Recovery to Microsoft AzureSharePoint Disaster Recovery to Microsoft Azure
SharePoint Disaster Recovery to Microsoft Azure
David J Rosenthal
 
Squid Caching for Web Content Accerlation
Squid Caching for Web Content AccerlationSquid Caching for Web Content Accerlation
Squid Caching for Web Content Accerlation
rahul8590
 

Similar to The secret life of a dispatcher (Adobe CQ AEM) (20)

Cloud computing 3702
Cloud computing 3702Cloud computing 3702
Cloud computing 3702
 
WSO2 Dep Sync for Artifact Synchronization of Cluster Nodes
WSO2 Dep Sync for Artifact Synchronization of Cluster NodesWSO2 Dep Sync for Artifact Synchronization of Cluster Nodes
WSO2 Dep Sync for Artifact Synchronization of Cluster Nodes
 
[WSO2] Deployment Synchronizer for Deployment Artifact Synchronization Betwee...
[WSO2] Deployment Synchronizer for Deployment Artifact Synchronization Betwee...[WSO2] Deployment Synchronizer for Deployment Artifact Synchronization Betwee...
[WSO2] Deployment Synchronizer for Deployment Artifact Synchronization Betwee...
 
More Cache for Less Cash (DevLink 2014)
More Cache for Less Cash (DevLink 2014)More Cache for Less Cash (DevLink 2014)
More Cache for Less Cash (DevLink 2014)
 
AWS re:Invent 2016: Amazon CloudFront Flash Talks: Best Practices on Configur...
AWS re:Invent 2016: Amazon CloudFront Flash Talks: Best Practices on Configur...AWS re:Invent 2016: Amazon CloudFront Flash Talks: Best Practices on Configur...
AWS re:Invent 2016: Amazon CloudFront Flash Talks: Best Practices on Configur...
 
AAI-3218 Production Deployment Best Practices for WebSphere Liberty Profile
AAI-3218 Production Deployment Best Practices for WebSphere Liberty ProfileAAI-3218 Production Deployment Best Practices for WebSphere Liberty Profile
AAI-3218 Production Deployment Best Practices for WebSphere Liberty Profile
 
Crikeycon 2019 Velociraptor Workshop
Crikeycon 2019 Velociraptor WorkshopCrikeycon 2019 Velociraptor Workshop
Crikeycon 2019 Velociraptor Workshop
 
Drupal performance optimization Best Practices
Drupal performance optimization Best PracticesDrupal performance optimization Best Practices
Drupal performance optimization Best Practices
 
Docker based Architecture by Denys Serdiuk
Docker based Architecture by Denys SerdiukDocker based Architecture by Denys Serdiuk
Docker based Architecture by Denys Serdiuk
 
SharePoint Disaster Recovery to Microsoft Azure
SharePoint Disaster Recovery to Microsoft AzureSharePoint Disaster Recovery to Microsoft Azure
SharePoint Disaster Recovery to Microsoft Azure
 
Where is my cache architectural patterns for caching microservices by example
Where is my cache architectural patterns for caching microservices by exampleWhere is my cache architectural patterns for caching microservices by example
Where is my cache architectural patterns for caching microservices by example
 
Scaling PHP apps
Scaling PHP appsScaling PHP apps
Scaling PHP apps
 
Introduction to node js - From "hello world" to deploying on azure
Introduction to node js - From "hello world" to deploying on azureIntroduction to node js - From "hello world" to deploying on azure
Introduction to node js - From "hello world" to deploying on azure
 
Squid Caching for Web Content Accerlation
Squid Caching for Web Content AccerlationSquid Caching for Web Content Accerlation
Squid Caching for Web Content Accerlation
 
FIWARE Tech Summit - Docker Swarm Secrets for Creating Great FIWARE Platforms
FIWARE Tech Summit - Docker Swarm Secrets for Creating Great FIWARE PlatformsFIWARE Tech Summit - Docker Swarm Secrets for Creating Great FIWARE Platforms
FIWARE Tech Summit - Docker Swarm Secrets for Creating Great FIWARE Platforms
 
Deploying windows containers with kubernetes
Deploying windows containers with kubernetesDeploying windows containers with kubernetes
Deploying windows containers with kubernetes
 
How to Build a Multi-DC Cassandra Cluster in AWS with OpsCenter LCM
How to Build a Multi-DC Cassandra Cluster in AWS with OpsCenter LCMHow to Build a Multi-DC Cassandra Cluster in AWS with OpsCenter LCM
How to Build a Multi-DC Cassandra Cluster in AWS with OpsCenter LCM
 
Orchestration Tool Roundup - Arthur Berezin & Trammell Scruggs
Orchestration Tool Roundup - Arthur Berezin & Trammell ScruggsOrchestration Tool Roundup - Arthur Berezin & Trammell Scruggs
Orchestration Tool Roundup - Arthur Berezin & Trammell Scruggs
 
High Availability Content Caching with NGINX
High Availability Content Caching with NGINXHigh Availability Content Caching with NGINX
High Availability Content Caching with NGINX
 
Containers orchestrators: Docker vs. Kubernetes
Containers orchestrators: Docker vs. KubernetesContainers orchestrators: Docker vs. Kubernetes
Containers orchestrators: Docker vs. Kubernetes
 

Recently uploaded

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Recently uploaded (20)

Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
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...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
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...
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
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
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 

The secret life of a dispatcher (Adobe CQ AEM)

  • 1. The Secret Life of CQ Dispatcher Venu Gummadala
  • 2. What is a Dispatcher? ➲ A load balancing & ➲ A caching tool
  • 3. Dispatcher – A Load Balancer CQ1CQ1CQ1 CQ3CQ2 Web server Dispatcher Client
  • 4. Dispatcher – A Caching Tool CQ Web server Dispatcher Client Dynamic Content Remote Content Static Content
  • 5. Why Use It ? ➲ As a load balancer prevents system from crashing by distributing requests among cq server instances. ➲ As a caching tool improves performance by serving static content locally from your web server.
  • 6. But … ➲ You can also use it behind a physical load balancer. ➲ You can also use it for a single CQ instance. ➲ It is also valid for both Author & Publisher environments.
  • 7. But .. why not CDNs? *should not be compared with CDNs … really ➲ CDNs are also caching tools ➲ CDNs serve digital assets from a geographical location near to you ➲ CDN is a implemented using a Provider ➲ Dispatcher is OTB and made for CQ
  • 8. more than a CDN ➲ By serving static content from Web server process it reduces load on CQ server ➲ By enforcing rules it filters un-wanted traffic at the web server level itself ➲ By re-writing urls it protects CQ from hackers realizing the content paths ➲ By blocking url patterns, headers ensures added protection & system failure.
  • 9. more than a CDN... Continued ➲ Gives the ability to include SSIs before request goes to CQ instance ➲ Improves User Experience on the site by responding quickly when serving static content ➲ Finally .. gives more control how you mange (delete or retain) cached files
  • 10. ➲ Just a module and a config file to be used on a web server ➲ Usually obtained from daycare ➲ Supported web servers :- Apache Web Server – 2.0, 2.2 & 2.4 Microsoft IIS – 7.0, 7.5 & 8.0 & Oracle iPlanet Web server – 7.0 ➲ Instructions to install dev.day.com/install How to install?
  • 11. How to configure? ➲ Edit your dispatcher.any file using any Editor. ➲ Sample dispatcher code structure.. /website { /clientheaders { } /virtualhosts { } /sessionmanagement { } /renders { } /filter { } /cache { /rules { } ➲ * preconfigured sample file here
  • 12. /cache   {    /docroot "/opt/dispatcher/cache"    /statfile  "/tmp/dispatcher-website.stat"             /allowAuthorized "0"   /rules   {    /0000  { /glob "*" /type "allow" }    /0001  { /glob "/en/news/*" /type "deny" }    /0002  { /glob "*/private/*" /type "deny"  }      } ➲ What is cached ? Ans: Everything (specified by '*' and 'allow')  ➲ What is not cached? ( Or what not to cache ? ) Ans: Content under /en/news path & url containing private path ➲ Why ?  Ans: news can be a feed getting constant updates       private can be personalization or profile data ➲ What is docroot? Ans: location on your webserver where cached content is saved ➲ What is a statfile? Ans: A file that manages the register of the last time the content was updated ➲ What is allowAuthorized? Ans: A flag to indicate if auth header, auth cookie & login-token cookie can b cached   What is Cached ? & what is not ?
  • 13. What is not Cached … ➲ Urls without file extensions e.g. /content/en is not cached ➲ Urls with query string parameters e.g. /content/en/blog/recipe.html?user='amy' is not cached ➲ HTTP 'post' method ➲ HTTP response status != '200 OK' ➲ Header response with 'Dispatcher: no-cache' What is Cached ? ... Continued & what is not ?
  • 14. Dispatcher As a Security Tool ➲ Use filter to allow/deny actions &  access to paths/content/tools    Example /filter {  /0001 { /type "deny" /method "POST" /url "/etc/*" }  /0002 { /type "allow" /method "GET" /url "/etc/*" /query "a=*" }  /0003 { /type "deny"  /glob "GET *.infinity.json*" }  /0004 { /type "allow" /glob "* *.js *"    }  # enable javascript  /0005     {     /glob "* /publish/libs/cq/workflow/content/console/archive*"     /type "deny"    } } 0001: Deny all POST methods 0002: Allow GET methods with query parameter = a 0003: Prevent json content dumps 0004: Allow javascript resource files  0005: Deny access to protected areas & tools .. workflow console in this case. 
  • 15. Dispatcher As a Security Tool   ➲ Use virtualhosts for ● Domain mapping ● Re-write urls etc. ➲ Example /virtualhosts       {       "www.isoap.com"       }     /renders       {       /hostname "internal.isoap.com"       /port "4503"       }
  • 16. Appendix ➲ What is static content ? Content which may remain un-changed for a specific amount of time. For e.g. images, scripts, error pages etc. ➲ What is Dynamic Content? Content which may change with time such as a Sports Score Card, User Blogs, News etc.
  • 17. More ? ➲ dev.day.com/more ➲ Even more ? ➲ How to configure a publisher environment ? ➲ Even more performance tweaks ? ➲ Deployment landscape & process ? ➲ For commercial implementations Contact: Venu.Gummadala@gmail.com Thank you ...