I have a weird problem - Some class file couldn\'t be read during maven build.
A
and project B
.It COULD be due to insufficient heap memory.
It sounds strange, but try it, it might just work:
export MAVEN_OPTS='-Xms384M -Xmx512M -XX:MaxPermSize=256M'
Source: https://groups.google.com/group/neo4j/msg/e208be9ee1c101d7)
Just now I also met the problem
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project entry-api: Compilation failure: Compilation failure:
package com.foo.entry.common.domain does not exist
package com.foo.entry.common.model does not exist
package com.foo.entry.common.service does not exist
package com.foo.entry.common.util does not exist
Took a long time got the reason, that is one of the dependency jar is spring boot fat jar
, so the solution is move below code in its pom.xml
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
i have an error like this, but after
1/
mvn eclipse:clean
mvn eclipse:eclipse -Dwtpversion=2.0
2/ run eclipse, and open the project
3/
mvn package
it's work
If your dependencies are fine (check with mvn dependency:list) like mine were, then it's a maven glitch, if you're using Eclipse do:
You should be good.
I don't know the equivalent mvn commands, if anyone could post them they could be useful.
Add <sourceDirectory>src</sourceDirectory>
in your pom.xml with proper reference. Adding this solved my problem
Inside in yours classses on which is complain maven is some dependecy which belongs to some jar's try right these jars re-build with maven command, i use this command mvn clean install -DskipTests=true
should be work in this case when some symbols from classes is missing