Skip to content

Spring Boot runner with top-level package duplicate does not work #614

@sukrit007

Description

@sukrit007

Given:
A Spring boot application integrated with Jersey 2.7, Jerse-Spring3 (2.7)
https://github.com/sukrit007/springboot-jersey

And:
An empty/non-empty folder, "com" in resources folder.

When:
I run Spring boot application

mvn spring-boot:run

Then:
My application fails with error:

[WARNING] 
java.lang.ClassNotFoundException: com.geowarin.Application
    at java.net.URLClassLoader$1.run(URLClassLoader.java:372)
    at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:360)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
    at org.springframework.boot.maven.RunMojo$LaunchRunner.run(RunMojo.java:304)
    at java.lang.Thread.run(Thread.java:744)

When:
I remove the folder com and run the application again.

Then:
My application starts working.

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