John M John M - 1 year ago 94
Java Question

Maven compile error (asking for a higher JDK version)

I made a new project today and wanted to compile with Maven (I'm running it on IntelliJ). Made sure to change the JDK level to 1.8, which is what I currently use, tried to compile and I'm getting a lot of exceptions asking me to use the "-source 8" argument since the default one is 1.5, and I'm using features of newer JDK versions.

I haven't been using IntelliJ for a long time, could anyone please tell me how to change these Maven compile arguments or how to solve this issue?

Answer Source

You add this to your pom.xml



Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download