Skip to content

Instantly share code, notes, and snippets.

@karanmalhi
Created December 6, 2011 21:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save karanmalhi/1440048 to your computer and use it in GitHub Desktop.
Save karanmalhi/1440048 to your computer and use it in GitHub Desktop.
Used to configure workers
#The list of workers
worker.list=balancer,stats
#The template contains default values. Each worker will inherit
#these values and override the port
# the worker type
worker.template.type=ajp13
#This could also be an IP address. Since all Tomcat instances
#and IIS are installed on the same host, hence "localhost"
#will suffice as the value
worker.template.host=localhost
# AJP port should match the one in server.xml
worker.template.port=8009
#load balancing factor
worker.template.lbfactor=1
#worker0 inherits everything from template
worker.worker0.reference=worker.template
#worker1 inherits from template but overrides port
worker.worker1.reference=worker.template
worker.worker1.port=8010
#worker2 inherits from template but overrides port
worker.worker2.reference=worker.template
worker.worker2.port=8011
#The load balancer worker
worker.balancer.type=lb
worker.balancer.sticky_session=1 #session is sticky
#List of workers amongst which load is distributed
worker.balancer.balance_workers=worker0,worker1,worker2
#The worker stats will be of type status
#will get load balancing statistics
worker.stats.type=status
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment