Skip to content

Web app that depends on Groovy but does not depend on spring-webmvc fails to start with NoClassDefFoundError: org/springframework/web/servlet/view/UrlBasedViewResolver #1793

Closed
@wilkinsona

Description

@wilkinsona

These dependencies will trigger the problem:

compile 'org.springframework.boot:spring-boot-starter'
compile 'org.springframework.boot:spring-boot-starter-tomcat'
compile 'org.codehaus.groovy:groovy-all:2.3.7'
compile 'org.springframework:spring-web'

The failure is NoClassDefFoundError: org/springframework/web/servlet/view/UrlBasedViewResolver

You can work around the problem by excluding GroovyTemplateAutoConfiguration:

@EnableAutoConfiguration(exclude=GroovyTemplateAutoConfiguration.class)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions