We actually run our internal CF sites in distributed mode. CF10+ works
better than 9-.  Previously it seems to work very slow and the clustering
well, just plain sucked.  And yes, you can accomplish pretty much the same
thing with reverse proxy.

The distributed methodology is still useful (proxy or connector method) as
CF can still peg CPU from time to time, and if you have other non-CF sites
on the web server (we have like 10 others), it is nice to have these
running while the lone CF site dies a horrible death on different servers.

My best suggestion for easily configuring, would be to install IIS on the
CF server, run the wsconfig.exe in the
c:\ColdFusion10\cfusion\runtime\bin.  This will create the configuration
files as well as the handler mappings and virtual directory for the
isapi_redirect.dll.  Don't remove these so you can use them as a reference
for setting up your web servers the same way.

Copy the c:\ColdFusion10\config to your web server from the CF server. Then
recreate the IIS handler mappings and jakarta virtual directory to mimic
the CF server's IIS configuration.  You will also have to add the
isapi_redirect.dll as an allowed executable. You can see this on the CF
server as well in IIS under the server root ISAPI restrictions.  Make sure
the website application pool user has write permission to the 'config'
directory.

The connector is more beneficial than a proxy in my opinion, as if you have
more than one CF server on the backend, it can act as a load balancer of
sorts.  We have 12 CF instances backing our stuff, you can manually change
the isapi_redirect worker files to create a pseudo cluster.  You can also
do things like redirect specific sites or sub-folders to a particular CF
instances.

One example I have is a CF service that routinely timeout and kills the
server (as it calls another SOAP service off-site).  I have this particular
file redirected to one of the CF instances to minimize it killing others
and effecting other sites.

You can probably do the pseudo clustering as well with a redirect proxy.
But the connector seems to be a more simple solution IMHO.  20 ways to
catch a fish.

The documentation for the Tomcat connnector is here:
http://tomcat.apache.org/connectors-doc/reference/iis.html

Don't follow the instructions for setting it up with IIS, it has stuff
about registry keys and such, and they are not necessary.  Just use it for
a reference for the properties in the config files.

Here is a snippet from our workers.properties file for the cluster (oh when
I say cluster it's not really a CF cluster, the connector acts like a
simple load balancer between your CF instances).  Your ports may differ
than 8013.  I think 8009 is the default.  You can see this in your CF
instance in the web.xml file for tomcat
under: c$\ColdFusion10\cfusion\runtime\conf\server.xml.  Look for something
like this, which also may be commented out.  If so you will need to
un-comment and restart CF.

<Connector port="8013" redirectPort="8443" protocol="AJP/1.3"
tomcatAuthentication="false"/>


# workers.properties
worker.list=cluster-1

worker.cluster-1.type=lb
worker.cluster-1.balance_workers=cfusion-3,cfusion-5
worker.cluster-1.sticky_session=true


worker.cfusion-3.type=ajp13
worker.cfusion-3.host=10.78.4.57
worker.cfusion-3.port=8013
worker.cfusion-3.max_reuse_connections=250
worker.cfusion-3.lbfactor=1
worker.cfusion-3.route=cfusion-3

worker.cfusion-5.type=ajp13
worker.cfusion-5.host=10.78.4.58
worker.cfusion-5.port=8013
worker.cfusion-5.max_reuse_connections=250
worker.cfusion-5.lbfactor=1
worker.cfusion-5.route=cfusion-5

Then your uriworkermap.properties would look something like this, we
removed some of the default stuff:

# uriworkermap.properties

/rest/* = cluster-1
/*.cfml/* = cluster-1
/*.mxml = cluster-1
/*.cfm = cluster-1
/*.cfm/* = cluster-1
/*.cfml = cluster-1
/*.cfc = cluster-1
/*.cfc/* = cluster-1

Since you've used this in the past you probably already know, it's a good
idea to mimic the same directory structure for your web apps between CF and
web server.  We use DFRS to replicate all the files, but other methods will
work as well.

Good Luck.

~Byron
--I am having a Poodle of a day.


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:359486
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to