Class BucketingUtil
- java.lang.Object
-
- com.evolveum.midpoint.schema.util.task.BucketingUtil
-
public class BucketingUtil extends Object
Methods related to bucketing part of an activity state and activity distribution definition.
-
-
Constructor Summary
Constructors Constructor Description BucketingUtil()
-
Method Summary
-
-
-
Method Detail
-
findBucketByNumber
public static WorkBucketType findBucketByNumber(List<WorkBucketType> buckets, int sequentialNumber)
-
findBucketByNumberRequired
@NotNull public static @NotNull WorkBucketType findBucketByNumberRequired(List<WorkBucketType> buckets, int sequentialNumber)
-
sortBucketsBySequentialNumber
public static void sortBucketsBySequentialNumber(List<WorkBucketType> buckets)
-
getWorkSegmentationConfiguration
@Nullable public static @Nullable AbstractWorkSegmentationType getWorkSegmentationConfiguration(BucketsDefinitionType buckets)
-
getCompleteBucketsNumber
public static int getCompleteBucketsNumber(@NotNull @NotNull List<WorkBucketType> buckets)
Returns the number of buckets that are marked as COMPLETE. They may be implicitly present.
-
getLastBucket
@Nullable public static @Nullable WorkBucketType getLastBucket(List<WorkBucketType> buckets)
-
hasLimitations
public static boolean hasLimitations(WorkBucketType bucket)
-
isCoordinator
public static boolean isCoordinator(@Nullable @Nullable ActivityStateType state)
-
isStandalone
public static boolean isStandalone(@Nullable @Nullable ActivityStateType state)
-
getBuckets
@NotNull public static @NotNull List<WorkBucketType> getBuckets(@NotNull @NotNull TaskActivityStateType taskState, @NotNull @NotNull ActivityPath activityPath)
-
getBuckets
@NotNull public static @NotNull List<WorkBucketType> getBuckets(@NotNull @NotNull ActivityStateType state)
-
getNumberOfBuckets
public static Integer getNumberOfBuckets(@NotNull @NotNull ActivityStateType state)
-
hasNonTrivialBuckets
public static boolean hasNonTrivialBuckets(@NotNull @NotNull ActivityStateType state)
A little guesswork for now.
-
isScavenger
public static boolean isScavenger(TaskActivityStateType taskState, ActivityPath activityPath)
-
isInScavengingPhase
public static boolean isInScavengingPhase(TaskActivityStateType taskState, ActivityPath activityPath)
-
isWorkComplete
public static boolean isWorkComplete(ActivityStateType state)
-
getWorkerOid
@Nullable public static @Nullable String getWorkerOid(@NotNull @NotNull WorkBucketType bucket)
-
isDelegatedTo
public static boolean isDelegatedTo(@NotNull @NotNull WorkBucketType bucket, @NotNull @NotNull String workerOid)
-
getSequentialNumbers
@NotNull public static @NotNull Set<Integer> getSequentialNumbers(@NotNull @NotNull Collection<WorkBucketType> buckets)
-
-