Collection<ComponentConfig> componentConfigs = ComponentConfig.getAllComponents();
if (componentConfigs != null) {
for (Object componentConfig : componentConfigs) {
ComponentConfig component = (ComponentConfig) componentConfig;
for (ComponentConfig.WebappInfo webappInfo : component.getWebappInfos()) {
List<String> virtualHosts = webappInfo.getVirtualHosts();
Map<String, String> initParameters = webappInfo.getInitParameters();
Server server = servers.get(webappInfo.server);
if (server == null) {
Debug.logWarning("Server with name [" + webappInfo.server + "] not found; not mounting [" + webappInfo.name + "]", module);
} else {
// set the root location (make sure we set the paths correctly)
String location = component.getRootLocation() + webappInfo.location;
location = location.replace('\\', '/');
if (location.endsWith("/")) {
location = location.substring(0, location.lastIndexOf("/"));
}