Need clarification for running 2 Lucee instances on same server

Currently we are running 2 different instances of ACF on same server, can it be possible with Lucee as well to run 2 different instances on same server?
Thanks in Advance!!!

other Details:
OS: Windows 10
Lucee version: 5.3.8
Azul Java : 11.0.12

You install lucee twice with different ports, e.g. 8888 and 9999.
You enable an apache2 module with balancers and update the apache2.conf like this:

# Add Cookie with ROUTEID so all requests remain on the same instance
Header add Set-Cookie "ROUTEID=.%{BALANCER_WORKER_ROUTE}e; path=/" env=BALANCER_ROUTE_CHANGED

# Webinterface to check and adjust the balancing
<Location "/balancer-manager">
    SetHandler balancer-manager
</Location>

# All statuscodes 2.. or 3.. are good
ProxyHCExpr 23 {%{REQUEST_STATUS} =~ /^[23]/}

# 2 Cluster Members. Check every 30 secs the status.cfm with a HEAD request, needs 2 passes to enable the member
 <Proxy balancer://mycluster>
     BalancerMember "http://127.0.0.1:9999" route=1 hcmethod=HEAD hcinterval=30 hcpasses=1 hcuri=/status.cfm
     BalancerMember "http://127.0.0.1:8888" route=2 hcmethod=HEAD hcinterval=30 hcpasses=1 hcuri=/status.cfm

     ProxySet stickysession=ROUTEID
</Proxy>
<IfModule mod_proxy.c>
        ProxyPreserveHost On
        ProxyPassMatch ^/(.+\.cf[cm])(/.*)?$ balancer://mycluster
        ProxyPassMatch ^/(.+\.cfchart)(/.*)?$ balancer://mycluster
        ProxyPassMatch ^/(.+\.cfml)(/.*)?$ balancer://mycluster
        ProxyPassReverse / balancer://mycluster
</IfModule>

I hope, this helps you.

2 Likes

Thanks for quick reply. I will try this.