-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(version): update to version 'v0.4.0'.
- Loading branch information
Showing
129 changed files
with
4,467 additions
and
3,912 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 3 additions & 6 deletions
9
cli/src/main/java/io/kestra/cli/commands/servers/StandAloneCommand.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
68 changes: 68 additions & 0 deletions
68
core/src/main/java/io/kestra/core/annotations/Retryable.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
package io.kestra.core.annotations; | ||
|
||
import io.micronaut.aop.Around; | ||
import io.micronaut.context.annotation.AliasFor; | ||
import io.micronaut.context.annotation.Type; | ||
import io.micronaut.retry.annotation.DefaultRetryPredicate; | ||
import io.micronaut.retry.annotation.RetryPredicate; | ||
import io.micronaut.retry.intercept.OverrideRetryInterceptor; | ||
|
||
import java.lang.annotation.*; | ||
|
||
import javax.validation.constraints.Digits; | ||
|
||
import static java.lang.annotation.RetentionPolicy.RUNTIME; | ||
|
||
@Inherited | ||
@Documented | ||
@Retention(RUNTIME) | ||
@Target({ElementType.METHOD, ElementType.TYPE, ElementType.ANNOTATION_TYPE}) | ||
@Around | ||
@Type(OverrideRetryInterceptor.class) | ||
public @interface Retryable { | ||
int MAX_INTEGRAL_DIGITS = 4; | ||
|
||
/** | ||
* @return The exception types to include (defaults to all) | ||
*/ | ||
Class<? extends Throwable>[] value() default {}; | ||
|
||
/** | ||
* @return The exception types to include (defaults to all) | ||
*/ | ||
@AliasFor(member = "value") | ||
Class<? extends Throwable>[] includes() default {}; | ||
|
||
/** | ||
* @return The exception types to exclude (defaults to none) | ||
*/ | ||
Class<? extends Throwable>[] excludes() default {}; | ||
|
||
/** | ||
* @return The maximum number of retry attempts | ||
*/ | ||
@Digits(integer = MAX_INTEGRAL_DIGITS, fraction = 0) | ||
String attempts() default "${kestra.retries.attempts:5}"; | ||
|
||
/** | ||
* @return The delay between retry attempts | ||
*/ | ||
String delay() default "${kestra.retries.delay:1s}"; | ||
|
||
/** | ||
* @return The maximum overall delay | ||
*/ | ||
String maxDelay() default "${kestra.retries.max-delay:}"; | ||
|
||
/** | ||
* @return The multiplier to use to calculate the delay | ||
*/ | ||
@Digits(integer = 2, fraction = 2) | ||
String multiplier() default "${kestra.retries.multiplier:2.0}"; | ||
|
||
/** | ||
* @return The retry predicate class to use instead of {@link io.micronaut.retry.annotation.Retryable#includes} and {@link io.micronaut.retry.annotation.Retryable#excludes} | ||
* (defaults to none) | ||
*/ | ||
Class<? extends RetryPredicate> predicate() default DefaultRetryPredicate.class; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.