java.lang.Object
com.netflix.genie.web.data.services.impl.jpa.queries.predicates.JobPredicates

public final class JobPredicates extends Object
Predicate helpers for querying JobEntity.
  • Method Details

    • getFindPredicate

      public static javax.persistence.criteria.Predicate getFindPredicate(javax.persistence.criteria.Root<JobEntity> root, javax.persistence.criteria.CriteriaBuilder cb, @Nullable String id, @Nullable String name, @Nullable String user, @Nullable Set<String> statuses, @Nullable Set<String> tags, @Nullable String clusterName, @Nullable ClusterEntity cluster, @Nullable String commandName, @Nullable CommandEntity command, @Nullable Instant minStarted, @Nullable Instant maxStarted, @Nullable Instant minFinished, @Nullable Instant maxFinished, @Nullable String grouping, @Nullable String groupingInstance)
      Generate a criteria query predicate for a where clause based on the given parameters.
      Parameters:
      root - The root to use
      cb - The criteria builder to use
      id - The job id
      name - The job name
      user - The user who created the job
      statuses - The job statuses
      tags - The tags for the jobs to find
      clusterName - The cluster name
      cluster - The cluster the job should have been run on
      commandName - The command name
      command - The command the job should have been run with
      minStarted - The time which the job had to start after in order to be return (inclusive)
      maxStarted - The time which the job had to start before in order to be returned (exclusive)
      minFinished - The time which the job had to finish after in order to be return (inclusive)
      maxFinished - The time which the job had to finish before in order to be returned (exclusive)
      grouping - The job grouping to search for
      groupingInstance - The job grouping instance to search for
      Returns:
      The specification