Within IntelliJ, open pom.xml file.
Add this section before <dependencies>
(if your file already has a <properties>
section, just add the <maven.compiler...>
lines below to that existing section):
<properties>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
</properties>