After you establish the good one MAVEN project, if there is no Src/main/java folder under the Java Resources Resource file, and you manually create the file, you are prompted for "existing file." This shows that in this project configuration already has Src/main/java this folder, as for why not show, I am still not clear, hope who understand with me under, thanks. (resolved) The first method: Open the project's Classpath file: The following <?xml version="1.0"encoding="UTF-8"?>
<classpath>
<classpathentry kind="src"output="Target/test-classes"Path="Src/test/java">
<
attributes>
<attribute
name="Optional"
value="true"/>
<attribute
name="Maven.pomderived"
value="true"/>
</
attributes>
</classpathentry>
<classpathentry kind="src"Path="Src/main/java"/>
<classpathentry kind="src"Path="Src/main/resources"/>
<classpathentry kind="src"output="Target/test-classes"Path="Src/test/resources"/>
<classpathentry kind="Con"Path="Org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<
attributes>
<attribute
name="Maven.pomderived"
value="true"/>
<attribute
name="Org.eclipse.jst.component.dependency"
value="/web-inf/lib"/>
</
attributes>
</classpathentry>
<classpathentry kind="Con"Path="org.eclipse.jdt.launching.jre_container/org.eclipse.jdt.internal.debug.ui.launcher.standardvmtype/ JavaSE-1.6 ">
<
attributes>
<attribute
name="Owner.project.facets"
value="Java"/>
</
attributes>
</classpathentry>
<classpathentry kind="Output"Path="Target/classes"/>
</classpath> will appear with the Path property: Src/main/java's Classpathentry node, then delete the nodes we need to create, such as <classpathentry kind="src"Path="Src/main/java"/>. If you re-establish the Src/main/java folder under Java Resources, there will be no problem. The second method: This is the most convenient one. On the project, right-select Properties, then click Java Build Path, under Librarys, edit the JRE System Library, select workspace Default JRE.
Workaround for the Src/main/java Resource folder cannot be established after Eclipse builds the MAVEN project