export-http-lb-config / appserver bug
We've encountered a bug in the loadbalancer.xml configuration file generated from this command (export-http-lb-config).
The problem occurs when, accidentally, you have more than one application deployed on the appserver with the same context root.
While this shouldn't happen, it's currently allowed. Tested in 8.1EE
For example, two apps that deploy to "/appname"
Trouble is, when you run "export-http-lb-config" it will generate an invalid XML file that the loadbalancer doesn't like. It will generate a file with two entries for the same context root.
ie
<web-module context-root="appname" disable-timeout-in-minutes="30" enabled="true" />
<web-module context-root="appname" disable-timeout-in-minutes="30" enabled="true" />
The loadbalancer plugin doesn't like this.
Although not valid, this isn't meant to cause a fatal error - the loadbalancer is meant to just stick with the existing configuration.
Trouble is, when the loadbalancer is installed on Apache, which is by default multi-process, if a new process is spawned, then it has to start a new load balancer instance, which doesn't work because the new loadbalancer.xml config file is invalid. Hence that Apache worker is dead (500 server error).
I suspect the problem might be better solved in the appserver.
It doesn't make a great deal of sense to allow more than one application to be deployed at the context root. The deployer should check this and fail if its the case.

