@axtavt is right, add source level configuration to your project. But do not configure maven-compiler-plugin
, simply put this properties into pom.xml
.
<properties>
<maven.compiler.source>1.7</maven.compiler.source>
<maven.compiler.target>1.7</maven.compiler.target>
</properties>
After this refresh maven configuration in Eclipse.