ERROR - Compilation unit is not on the build path of a java project using Eclipse, SVN and Maven

Error

"Compilation unit is not on the build path of a java project" upon checking out project from SVN and building it using Maven.

Cause

Project not checked out properly or not built properly.

Possible Resolution 1

Make sure that you checkout the SVN project using "checkout as project configured using the New Project Wizard".

Perform a Maven clean install and then Mvn eclipse:eclipse to refresh the eclipse projects.

Possible Resolution 2

Check out the projects using SVN command line

svn checkout <project>

Perform a Maven clean install and then Mvn eclipse:eclipse to refresh the eclipse projects.

Possible Resolution 3

Check your .project file and make sure that things are right with it.

Possible Resolution 4

Right click on your project ->Project Facets -> click on Java, then Apply.

Possible Resolution

Go to Project-> right Click-> Select Properties -> project Facets -> modify the java version for your JDK version you are using.