These are the settings I used:
Configuration in Apache:
========================
In file <APACHE_HOME>/conf/httpd.conf I add this row:
# Include mod_jk configuration file
Include conf/mod-jk.conf
------------------------------------------------------------------------
Create a mod-jk.conf into <APACHE_HOME>/conf
# Load mod_jk module
# Specify the filename of the mod_jk lib
LoadModule jk_module modules/mod_jk.so
# Where to find workers.properties
JkWorkersFile conf/workers.properties
# Where to put jk logs
JkLogFile logs/mod_jk.log
# Set the jk log level [debug/error/info]
JkLogLevel debug
# Select the log format
JkLogStampFormat "[%a %b %d %H:%M:%S %Y]"
# JkOptions indicates to send SSK KEY SIZE
JkOptions +ForwardKeySize +ForwardURICompat -ForwardDirectories
# JkRequestLogFormat
JkRequestLogFormat "%w %V %T"
# Mount your applications
JkMount /application/* loadbalancer
# You can use external file for mount points.
# It will be checked for updates each 60 seconds.
# The format of the file is: /url=worker
# /examples/*=loadbalancer
JkMountFile conf/uriworkermap.properties
# Add shared memory.
# This directive is present with 1.2.10 and
# later versions of mod_jk, and is needed for
# for load balancing to work properly
JkShmFile logs/jk.shm
# Add jkstatus for managing runtime data
<Location /jkstatus/>
JkMount status
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Location>
------------------------------------------------------------------------
File workers.properties:
# Define list of workers that will be used
# for mapping requests
# The configuration directives are valid
# for the mod_jk version 1.2.18 and later
worker.list=loadbalancer,status
# Load-balancing behaviour
worker.loadbalancer.type=lb
worker.loadbalancer.balance_workers=nodo2
worker.loadbalancer.sticky_session=1
# Definimos el nodo Nodo1
# Puerto del conector ajp de nuestro tomcat (JBoss)
#worker.nodo1.port=8009
# Ip del nodo 1.
#worker.nodo1.host=10.3.50.66
#worker.nodo1.type=ajp13
# Peso de nuestro nodo. A más peso, mas peticiones recibe.
#worker.nodo1.lbfactor=1
# Definimos el nodo Nodo2
worker.nodo2.port=8900
worker.nodo2.host=localhost
worker.nodo2.type=ajp13
worker.nodo2.lbfactor=1
# Status worker for managing load balancer
worker.status.type=status
------------------------------------------------------------------------
File uriworkermap.properties
# Simple worker configuration file
# Mount the Servlet context to the ajp13 worker
/jmx-console=loadbalancer
/jmx-console/*=loadbalancer
#/web-console=loadbalancer
#/web-console/*=loadbalancer
/orderReceiver=loadbalancer
/orderReceiver/*=loadbalancer
------------------------------------------------------------------------
Configuration in Jboss instance:
================================
In file <JBOSS_HOME>/server/all/deploy/cluster-service.xml TCP section have to be commented but instead of will be this section:
------------------------------------------------------------------------
In file jboss-web/deployer/server.xml:
Comment this part:
Uncomment this part:
Add:
------------------------------------------------------------------------
In file <JBOSS_HOME>/server/all/deploy/jboss-web.deployer/META-INF :
------------------------------------------------------------------------
In file <JBOSS_HOME>/server/all/deploy/jboss-web-cluster.sar/META-INF :