Class ConfigureMojo

java.lang.Object
org.apache.maven.plugin.AbstractMojo
ai.timefold.solver.tools.maven.AbstractPlatformModelMojo
ai.timefold.solver.tools.maven.ConfigureMojo
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

@Mojo(name="configure", defaultPhase=INITIALIZE, requiresDependencyResolution=COMPILE) public class ConfigureMojo extends AbstractPlatformModelMojo
  • Field Details

    • PROP_NAMESPACE

      protected static final String PROP_NAMESPACE
      See Also:
    • PROP_MODEL_NATIVE_SUPPORTED

      protected static final String PROP_MODEL_NATIVE_SUPPORTED
      See Also:
    • PROP_MODEL_CONFIG_SKIP

      protected static final String PROP_MODEL_CONFIG_SKIP
      See Also:
    • namespace

      @Parameter(property="timefold.namespace", required=false) protected String namespace
      Namespace that model is associated with
  • Constructor Details

    • ConfigureMojo

      public ConfigureMojo()
  • Method Details

    • execute

      public void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException
      Throws:
      org.apache.maven.plugin.MojoExecutionException
      org.apache.maven.plugin.MojoFailureException
    • resolveNamespace

      protected String resolveNamespace(PlatformIdentityInfo info) throws org.apache.maven.plugin.MojoFailureException
      Resolves the namespace the model is deployed under, which becomes the group of the container image. It is either configured explicitly, or, when the personal access token is associated with exactly one namespace, that namespace.
      Throws:
      org.apache.maven.plugin.MojoFailureException - when the namespace is neither configured nor unambiguously derivable from the personal access token; without it the container image cannot be named, so the build must not continue.
    • validateEnterpriseBuild

      protected void validateEnterpriseBuild() throws org.apache.maven.plugin.MojoFailureException
      Timefold Platform only accepts models that inherit from timefold-solver-service-parent and that are built with the Enterprise Edition. Such a model builds and deploys successfully, but fails later, when it actually runs, with errors that do not point at the missing profile.
      Throws:
      org.apache.maven.plugin.MojoFailureException
    • shouldExecute

      protected boolean shouldExecute()
    • getProject

      protected org.apache.maven.project.MavenProject getProject()