[ https://issues.apache.org/jira/browse/OFBIZ-4571?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Chatree Srichart updated OFBIZ-4571: ------------------------------------ Attachment: multiple_aliases.patch Confirming that it is a bug of Tomcat 7. The Tomcat Dev community filed an issue: https://issues.apache.org/bugzilla/show_bug.cgi?id=52225 He also gave me a solution to avoid this bug. I also attach a patch file to solve the problem. If there is not any objection, then please commit it to the trunk. Regares, Chatree Srichart > Tomcat 7 Multi Aliases Problem > ------------------------------ > > Key: OFBIZ-4571 > URL: https://issues.apache.org/jira/browse/OFBIZ-4571 > Project: OFBiz > Issue Type: Bug > Components: framework > Affects Versions: SVN trunk > Environment: Ubuntu > Reporter: Chatree Srichart > Priority: Critical > Labels: 7, alias, tomcat > Attachments: multiple_aliases.patch > > Original Estimate: 4m > Remaining Estimate: 4m > > I see Tomcat 7 give me a confusing about adding multiple aliases (virtual > hosts) to a webapp. I am not sure if it a bug of Tomcat 7 because it cannot > work if I add multiple virtual hosts to a webapp. It works for only the top > (first) virtual host. For example: > <webapp name="ecommerce" > title="eCommerce" > server="default-server" > location="webapp/ecommerce" > mount-point="/ecommerce" > app-bar-display="false"> > <virtual-host host-name="localhost1"/> > <virtual-host host-name="localhost2"/> > </webapp> > It will work only localhost1, localhost2 will not work. This is a log I got: > Nov 18, 2011 5:45:32 PM org.apache.coyote.http11.AbstractHttp11Processor > process > SEVERE: Error processing request > java.lang.ClassCastException: org.apache.tomcat.util.http.mapper.Mapper$Host > cannot be cast to org.apache.catalina.Host > at org.apache.catalina.connector.Request.getHost(Request.java:631) > at > org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:105) > at > org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:929) > at > org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:405) > at > org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:964) > at > org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:515) > at > org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:302) > at > java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) > at > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) > at java.lang.Thread.run(Thread.java:619) > Any idea? > Regards, > Chatree Srichart -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira