Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -21,21 +21,22 @@ private PostExecutionControl(
this.runtimeException = runtimeException;
}

public static PostExecutionControl onlyFinalizerAdded() {
return new PostExecutionControl(true, null, null);
public static <R extends CustomResource<?, ?>> PostExecutionControl<R> onlyFinalizerAdded() {
return new PostExecutionControl<>(true, null, null);
}

public static PostExecutionControl defaultDispatch() {
return new PostExecutionControl(false, null, null);
public static <R extends CustomResource<?, ?>> PostExecutionControl<R> defaultDispatch() {
return new PostExecutionControl<>(false, null, null);
}

public static <R extends CustomResource<?, ?>> PostExecutionControl<R> customResourceUpdated(
R updatedCustomResource) {
return new PostExecutionControl<>(false, updatedCustomResource, null);
}

public static PostExecutionControl exceptionDuringExecution(RuntimeException exception) {
return new PostExecutionControl(false, null, exception);
public static <R extends CustomResource<?, ?>> PostExecutionControl<R> exceptionDuringExecution(
RuntimeException exception) {
return new PostExecutionControl<>(false, null, exception);
}

public boolean isOnlyFinalizerHandled() {
Expand All @@ -54,7 +55,7 @@ public boolean exceptionDuringExecution() {
return runtimeException != null;
}

public PostExecutionControl withReSchedule(long delay) {
public PostExecutionControl<R> withReSchedule(long delay) {
this.reScheduleDelay = delay;
return this;
}
Expand Down