-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #44831 from Ladicek/fault-tolerance-6.7.0
SmallRye Fault Tolerance: upgrade to 6.7.0
- Loading branch information
Showing
48 changed files
with
2,126 additions
and
35 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
43 changes: 43 additions & 0 deletions
43
...loyment/src/main/java/io/quarkus/smallrye/faulttolerance/deployment/ConfigUtilJandex.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,43 @@ | ||
package io.quarkus.smallrye.faulttolerance.deployment; | ||
|
||
import java.lang.annotation.Annotation; | ||
|
||
import org.jboss.jandex.ClassInfo; | ||
import org.jboss.jandex.MethodInfo; | ||
|
||
import io.smallrye.faulttolerance.config.ConfigPrefix; | ||
import io.smallrye.faulttolerance.config.NewConfig; | ||
|
||
// copy of `io.smallrye.faulttolerance.config.ConfigUtil` and translation from reflection to Jandex | ||
final class ConfigUtilJandex { | ||
static final String GLOBAL = "global"; | ||
|
||
static String newKey(Class<? extends Annotation> annotation, String member, MethodInfo declaringMethod) { | ||
return ConfigPrefix.VALUE + "\"" + declaringMethod.declaringClass().name() + "/" + declaringMethod.name() | ||
+ "\"." + NewConfig.get(annotation, member); | ||
} | ||
|
||
static String oldKey(Class<? extends Annotation> annotation, String member, MethodInfo declaringMethod) { | ||
return declaringMethod.declaringClass().name() + "/" + declaringMethod.name() | ||
+ "/" + annotation.getSimpleName() + "/" + member; | ||
} | ||
|
||
static String newKey(Class<? extends Annotation> annotation, String member, ClassInfo declaringClass) { | ||
return ConfigPrefix.VALUE + "\"" + declaringClass.name() + "\"." | ||
+ NewConfig.get(annotation, member); | ||
} | ||
|
||
static String oldKey(Class<? extends Annotation> annotation, String member, ClassInfo declaringClass) { | ||
return declaringClass.name() + "/" + annotation.getSimpleName() + "/" + member; | ||
} | ||
|
||
static String newKey(Class<? extends Annotation> annotation, String member) { | ||
return ConfigPrefix.VALUE + GLOBAL + "." + NewConfig.get(annotation, member); | ||
} | ||
|
||
static String oldKey(Class<? extends Annotation> annotation, String member) { | ||
return annotation.getSimpleName() + "/" + member; | ||
} | ||
|
||
// no need to have the `isEnabled()` method, that is only needed at runtime | ||
} |
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.