title: Maven: compile Java 7 with JDK8
body: <p>I need to ensure one thing before doing it, so I have not yet tested the solution I'll propose.</p>
  
  <p>I have a <code>Jenkins</code> on which one project compiles with a <code>JDK 7</code> with target <code>Java 7</code>. I have a new project written in <code>Java 8</code>, and I'd like to add it to my <code>Jenkins</code>for it to build it too.</p>
  
  <p>As a consequence, I need to install a <code>JDK 8</code> on the machine. I know we can specify the java compiler version in the pom of each project, but I'm fearing this: once I have installed <code>JDK 8</code>, will my <code>Java 7</code> project still be able to compile with that <code>JDK 8</code>? Should I have the two <code>JDK</code> installed on the machine, and have a configuration for each project to be able to locate its own <code>JDK</code>? Or will my <code>Java 7</code> project be able to compile in <code>Java 7</code> using the <code>JDK 8</code> ?</p>
  
  <p>Thanks for any help.</p>