Repository: GoogleContainerTools/jib
File: jib-plugins-common/src/main/java/com/google/cloud/tools/jib/plugins/common/PluginConfigurationProcessor.java (Java)

Code before:
import javax.annotation.Nullable;

/**
 * Configures and provides {@code JibBuildRunner} for the image building tasks based on raw plugin
 * configuration values and project properties.
 */
public class PluginConfigurationProcessor {

  // Known "generated" dependencies -- these require that the underlying system run a build step
  // before they are available for sync'ing
  private static final ImmutableList<String> GENERATED_LAYERS =
      ImmutableList.of(
          LayerType.PROJECT_DEPENDENCIES.getName(),
          LayerType.RESOURCES.getName(),
          LayerType.CLASSES.getName());

  // Known "constant" layers -- changes to these layers require a change to the build definition,
  // which we consider non-syncable. These should not be included in the sync-map.
  private static final ImmutableList<String> CONST_LAYERS =
      ImmutableList.of(LayerType.DEPENDENCIES.getName(), LayerType.JVM_ARG_FILES.getName());

  private static final String DEFAULT_JETTY_APP_ROOT = "/var/lib/jetty/webapps/ROOT";

  private static final String JIB_CLASSPATH_FILE = "jib-classpath-file";
  private static final String JIB_MAIN_CLASS_FILE = "jib-main-class-file";
  private static final String DEFAULT_JIB_DIR = "src/main/jib";

  private PluginConfigurationProcessor() {}

  /**
   * Generate a runner for image builds to docker daemon.
   *
   * @param rawConfiguration the raw configuration from the plugin
   * @param inferredAuthProvider the plugin specific auth provider
   * @param projectProperties an plugin specific implementation of {@link ProjectProperties}
   * @param globalConfig the Jib global config
   * @param helpfulSuggestions a plugin specific instance of {@link HelpfulSuggestions}
   * @return new {@link JibBuildRunner} to execute a build
   * @throws InvalidImageReferenceException if the image reference is invalid
   * @throws MainClassInferenceException if a main class could not be found
   * @throws InvalidAppRootException if the specific path for application root is invalid
   * @throws IOException if an error occurs creating the container builder
   * @throws InvalidWorkingDirectoryException if the working directory specified for the build is
   *     invalid
   * @throws InvalidPlatformException if there exists a {@link PlatformConfiguration} in the
   *     specified platforms list that is missing required fields or has invalid values
   * @throws InvalidContainerVolumeException if a specific container volume is invalid
   * @throws IncompatibleBaseImageJavaVersionException if the base image java version cannot support
   *     this build
   * @throws NumberFormatException if a string to number conversion operation fails
   * @throws InvalidContainerizingModeException if an invalid {@link ContainerizingMode} was

Review comment (suggestion):
Not that this isn't going to work on Windows, but we just prefer this form:

```suggestion
  private static final Path DEFAULT_JIB_DIR = Paths.get("src").resolve("main").resolve("jib");
```

Code after:
import javax.annotation.Nullable;

/**
 * Configures and provides {@code JibBuildRunner} for the image building tasks based on raw plugin
 * configuration values and project properties.
 */
public class PluginConfigurationProcessor {

  // Known "generated" dependencies -- these require that the underlying system run a build step
  // before they are available for sync'ing
  private static final ImmutableList<String> GENERATED_LAYERS =
      ImmutableList.of(
          LayerType.PROJECT_DEPENDENCIES.getName(),
          LayerType.RESOURCES.getName(),
          LayerType.CLASSES.getName());

  // Known "constant" layers -- changes to these layers require a change to the build definition,
  // which we consider non-syncable. These should not be included in the sync-map.
  private static final ImmutableList<String> CONST_LAYERS =
      ImmutableList.of(LayerType.DEPENDENCIES.getName(), LayerType.JVM_ARG_FILES.getName());

  private static final String DEFAULT_JETTY_APP_ROOT = "/var/lib/jetty/webapps/ROOT";

  private static final String JIB_CLASSPATH_FILE = "jib-classpath-file";
  private static final String JIB_MAIN_CLASS_FILE = "jib-main-class-file";
  private static final Path DEFAULT_JIB_DIR = Paths.get("src").resolve("main").resolve("jib");

  private PluginConfigurationProcessor() {}

  /**
   * Generate a runner for image builds to docker daemon.
   *
   * @param rawConfiguration the raw configuration from the plugin
   * @param inferredAuthProvider the plugin specific auth provider
   * @param projectProperties an plugin specific implementation of {@link ProjectProperties}
   * @param globalConfig the Jib global config
   * @param helpfulSuggestions a plugin specific instance of {@link HelpfulSuggestions}
   * @return new {@link JibBuildRunner} to execute a build
   * @throws InvalidImageReferenceException if the image reference is invalid
   * @throws MainClassInferenceException if a main class could not be found
   * @throws InvalidAppRootException if the specific path for application root is invalid
   * @throws IOException if an error occurs creating the container builder
   * @throws InvalidWorkingDirectoryException if the working directory specified for the build is
   *     invalid
   * @throws InvalidPlatformException if there exists a {@link PlatformConfiguration} in the
   *     specified platforms list that is missing required fields or has invalid values
   * @throws InvalidContainerVolumeException if a specific container volume is invalid
   * @throws IncompatibleBaseImageJavaVersionException if the base image java version cannot support
   *     this build
   * @throws NumberFormatException if a string to number conversion operation fails
   * @throws InvalidContainerizingModeException if an invalid {@link ContainerizingMode} was