@Override
  public int getMajorJavaVersion() {
    // Check properties for version
    if (project.getProperties().getProperty("maven.compiler.target") != null) {
      return getVersionFromString(project.getProperties().getProperty("maven.compiler.target"));
    }
    if (project.getProperties().getProperty("maven.compiler.release") != null) {
      return getVersionFromString(project.getProperties().getProperty("maven.compiler.release"));
    }

    // Check maven-compiler-plugin for version
    Plugin mavenCompilerPlugin =
        project.getPlugin("org.apache.maven.plugins:maven-compiler-plugin");
    if (mavenCompilerPlugin != null) {
      Xpp3Dom pluginConfiguration = (Xpp3Dom) mavenCompilerPlugin.getConfiguration();
      Optional<String> target = getChildValue(pluginConfiguration, "target");
      if (target.isPresent()) {
        return getVersionFromString(target.get());
      }
      Optional<String> release = getChildValue(pluginConfiguration, "release");
      if (release.isPresent()) {
        return getVersionFromString(release.get());
      }
    }
    return 6; // maven-compiler-plugin default is 1.6
  }
Gets whether or not the given project is a war project. This is the case for projects with
packaging {@code war} and {@code gwt-app}.

@return {@code true} if the project is a war project, {@code false} if not
jib-maven-plugin/src/main/java/com/google/cloud/tools/jib/maven/MavenProjectProperties.java