Tomcat выдает HTTP status 404 - not found - Spring MVC

Пытаюсь запустить war файл на виртуальном Tomcat (Turnkey Tomcat Apache/Linux) - выдвет 404 The origin server did not find a current representation for the target resource or is not willing to disclose that one exists. Если запускаю в Intellij на встроенном Tomcat все работает отлично. Подскажите где искать проблему. Запускаю URL http://ipaddress/SpotifyAPI/start Добавил в mod_jk.conf:

JkMount /SpotifyAPI* ajp13_worker

public class DispatcherWebInit extends AbstractAnnotationConfigDispatcherServletInitializer {

    @Override
    protected Class<?>[] getRootConfigClasses() {
        return new Class[] {};
    }

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

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

    @Autowired
   private ClientService service;


    @GetMapping("/start")
    public String start() {
        return "index";
    }


    @PostMapping("/login")

......other methods........

@Configuration
@EnableWebMvc
@ComponentScan("spotify")
@EnableTransactionManagement
@PropertySource({ "/resources/persistence-postgresql.properties" })
public class AppConfig implements WebMvcConfigurer {

    private final ApplicationContext applicationContext;
    @Autowired
    private Environment env;

    private Logger logger = Logger.getLogger(getClass().getName());

    @Autowired
    public AppConfig(ApplicationContext applicationContext) {
        this.applicationContext = applicationContext;
    }

    @Bean
    public SpringResourceTemplateResolver templateResolver() {
        SpringResourceTemplateResolver templateResolver = new SpringResourceTemplateResolver();
        templateResolver.setApplicationContext(applicationContext);
        templateResolver.setPrefix("/WEB-INF/view/");
        templateResolver.setSuffix(".html");
        return templateResolver;
    }
    @Override
    public void addResourceHandlers(ResourceHandlerRegistry registry) {
        registry
                .addResourceHandler("/resources/**")
                .addResourceLocations("/resources/","/other-resources/")
                .setCachePeriod(3600)
                .resourceChain(true)
                .addResolver(new PathResourceResolver());
    }
.....some more configs......

введите сюда описание изображения


Ответы (0 шт):