0

作为主题,我的战争在 Jetty / Tomcat 上运行没有错误,但是当我将其部署到 Resin 4 时,它在树脂管理面板上的已部署应用程序选项卡中显示为正在运行/活动。日志中也没有异常。但是当我尝试访问 myapp 我得到 404

    Aug 14, 2013 9:20:25 AM com.caucho.server.cluster.Server start
INFO: resin.conf = null
Aug 14, 2013 9:20:25 AM com.caucho.server.cluster.Server start
INFO: 
Aug 14, 2013 9:20:25 AM com.caucho.lifecycle.Lifecycle toActive
INFO: Host[] active
Aug 14, 2013 9:20:25 AM com.caucho.server.port.Port bind
INFO: http listening to *:8080
Aug 14, 2013 9:20:25 AM com.caucho.lifecycle.Lifecycle toActive
INFO: Server[id=,cluster=] active
Aug 14, 2013 9:20:25 AM com.caucho.server.resin.Resin start
INFO: Resin started in 2804ms
Aug 14, 2013 9:20:25 AM com.caucho.lifecycle.Lifecycle toStopping
INFO: Host[] stopping
Aug 14, 2013 9:20:25 AM com.caucho.lifecycle.Lifecycle toActive
INFO: Host[] active
Aug 14, 2013 9:20:26 AM com.caucho.lifecycle.Lifecycle toActive
INFO: WebApp[http://localhost:8080/myapp] active

web 3.0 应用初始化程序

import com.opensymphony.sitemesh.webapp.SiteMeshFilter;
import org.springframework.core.annotation.Order;
import org.springframework.web.servlet.support.AbstractAnnotationConfigDispatcherServletInitializer;

import javax.servlet.Filter;

@Order(1)
public class AppWebApplicationInitializer extends AbstractAnnotationConfigDispatcherServletInitializer {
    @Override
    protected Class<?>[] getRootConfigClasses() {
        return new Class[]{RootConfiguration.class};
    }

    @Override
    protected Class<?>[] getServletConfigClasses() {
        return new Class[]{WebConfiguration.class};
    }

    @Override
    protected String[] getServletMappings() {
        return new String[]{"/"};
    }

    @Override
    protected Filter[] getServletFilters() {
        return new Filter[] { new SiteMeshFilter() };
    }
4

0 回答 0