This is an automated email from the ASF dual-hosted git repository.

davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/main by this push:
     new a88dcc1  CAMEL-17638: Fix reference to old style Ref property naming
a88dcc1 is described below

commit a88dcc124421f1b0d055c1fa6cbd0a661e11e09c
Author: Claus Ibsen <[email protected]>
AuthorDate: Mon Feb 28 11:22:40 2022 +0100

    CAMEL-17638: Fix reference to old style Ref property naming
---
 ...ilience4jConfigurationPropertiesConfigurer.java | 42 +++++++++++-----------
 .../camel-main-configuration-metadata.json         |  6 ++--
 core/camel-main/src/main/docs/main.adoc            |  6 ++--
 .../main/Resilience4jConfigurationProperties.java  | 36 +++++++++----------
 4 files changed, 45 insertions(+), 45 deletions(-)

diff --git 
a/core/camel-main/src/generated/java/org/apache/camel/main/Resilience4jConfigurationPropertiesConfigurer.java
 
b/core/camel-main/src/generated/java/org/apache/camel/main/Resilience4jConfigurationPropertiesConfigurer.java
index ac72bd0..5913431 100644
--- 
a/core/camel-main/src/generated/java/org/apache/camel/main/Resilience4jConfigurationPropertiesConfigurer.java
+++ 
b/core/camel-main/src/generated/java/org/apache/camel/main/Resilience4jConfigurationPropertiesConfigurer.java
@@ -24,8 +24,8 @@ public class Resilience4jConfigurationPropertiesConfigurer 
extends org.apache.ca
         map.put("BulkheadEnabled", java.lang.Boolean.class);
         map.put("BulkheadMaxConcurrentCalls", java.lang.Integer.class);
         map.put("BulkheadMaxWaitDuration", java.lang.Integer.class);
-        map.put("CircuitBreakerRef", java.lang.String.class);
-        map.put("ConfigRef", java.lang.String.class);
+        map.put("CircuitBreaker", java.lang.String.class);
+        map.put("Config", java.lang.String.class);
         map.put("FailureRateThreshold", java.lang.Float.class);
         map.put("MinimumNumberOfCalls", java.lang.Integer.class);
         map.put("PermittedNumberOfCallsInHalfOpenState", 
java.lang.Integer.class);
@@ -36,7 +36,7 @@ public class Resilience4jConfigurationPropertiesConfigurer 
extends org.apache.ca
         map.put("TimeoutCancelRunningFuture", java.lang.Boolean.class);
         map.put("TimeoutDuration", java.lang.Integer.class);
         map.put("TimeoutEnabled", java.lang.Boolean.class);
-        map.put("TimeoutExecutorServiceRef", java.lang.String.class);
+        map.put("TimeoutExecutorService", java.lang.String.class);
         map.put("WaitDurationInOpenState", java.lang.Integer.class);
         map.put("WritableStackTraceEnabled", java.lang.Boolean.class);
         ALL_OPTIONS = map;
@@ -55,10 +55,10 @@ public class Resilience4jConfigurationPropertiesConfigurer 
extends org.apache.ca
         case "BulkheadMaxConcurrentCalls": 
target.setBulkheadMaxConcurrentCalls(property(camelContext, 
java.lang.Integer.class, value)); return true;
         case "bulkheadmaxwaitduration":
         case "BulkheadMaxWaitDuration": 
target.setBulkheadMaxWaitDuration(property(camelContext, 
java.lang.Integer.class, value)); return true;
-        case "circuitbreakerref":
-        case "CircuitBreakerRef": 
target.setCircuitBreakerRef(property(camelContext, java.lang.String.class, 
value)); return true;
-        case "configref":
-        case "ConfigRef": target.setConfigRef(property(camelContext, 
java.lang.String.class, value)); return true;
+        case "circuitbreaker":
+        case "CircuitBreaker": target.setCircuitBreaker(property(camelContext, 
java.lang.String.class, value)); return true;
+        case "config":
+        case "Config": target.setConfig(property(camelContext, 
java.lang.String.class, value)); return true;
         case "failureratethreshold":
         case "FailureRateThreshold": 
target.setFailureRateThreshold(property(camelContext, java.lang.Float.class, 
value)); return true;
         case "minimumnumberofcalls":
@@ -79,8 +79,8 @@ public class Resilience4jConfigurationPropertiesConfigurer 
extends org.apache.ca
         case "TimeoutDuration": 
target.setTimeoutDuration(property(camelContext, java.lang.Integer.class, 
value)); return true;
         case "timeoutenabled":
         case "TimeoutEnabled": target.setTimeoutEnabled(property(camelContext, 
java.lang.Boolean.class, value)); return true;
-        case "timeoutexecutorserviceref":
-        case "TimeoutExecutorServiceRef": 
target.setTimeoutExecutorServiceRef(property(camelContext, 
java.lang.String.class, value)); return true;
+        case "timeoutexecutorservice":
+        case "TimeoutExecutorService": 
target.setTimeoutExecutorService(property(camelContext, java.lang.String.class, 
value)); return true;
         case "waitdurationinopenstate":
         case "WaitDurationInOpenState": 
target.setWaitDurationInOpenState(property(camelContext, 
java.lang.Integer.class, value)); return true;
         case "writablestacktraceenabled":
@@ -109,10 +109,10 @@ public class 
Resilience4jConfigurationPropertiesConfigurer extends org.apache.ca
         case "BulkheadMaxConcurrentCalls": return java.lang.Integer.class;
         case "bulkheadmaxwaitduration":
         case "BulkheadMaxWaitDuration": return java.lang.Integer.class;
-        case "circuitbreakerref":
-        case "CircuitBreakerRef": return java.lang.String.class;
-        case "configref":
-        case "ConfigRef": return java.lang.String.class;
+        case "circuitbreaker":
+        case "CircuitBreaker": return java.lang.String.class;
+        case "config":
+        case "Config": return java.lang.String.class;
         case "failureratethreshold":
         case "FailureRateThreshold": return java.lang.Float.class;
         case "minimumnumberofcalls":
@@ -133,8 +133,8 @@ public class Resilience4jConfigurationPropertiesConfigurer 
extends org.apache.ca
         case "TimeoutDuration": return java.lang.Integer.class;
         case "timeoutenabled":
         case "TimeoutEnabled": return java.lang.Boolean.class;
-        case "timeoutexecutorserviceref":
-        case "TimeoutExecutorServiceRef": return java.lang.String.class;
+        case "timeoutexecutorservice":
+        case "TimeoutExecutorService": return java.lang.String.class;
         case "waitdurationinopenstate":
         case "WaitDurationInOpenState": return java.lang.Integer.class;
         case "writablestacktraceenabled":
@@ -155,10 +155,10 @@ public class 
Resilience4jConfigurationPropertiesConfigurer extends org.apache.ca
         case "BulkheadMaxConcurrentCalls": return 
target.getBulkheadMaxConcurrentCalls();
         case "bulkheadmaxwaitduration":
         case "BulkheadMaxWaitDuration": return 
target.getBulkheadMaxWaitDuration();
-        case "circuitbreakerref":
-        case "CircuitBreakerRef": return target.getCircuitBreakerRef();
-        case "configref":
-        case "ConfigRef": return target.getConfigRef();
+        case "circuitbreaker":
+        case "CircuitBreaker": return target.getCircuitBreaker();
+        case "config":
+        case "Config": return target.getConfig();
         case "failureratethreshold":
         case "FailureRateThreshold": return target.getFailureRateThreshold();
         case "minimumnumberofcalls":
@@ -179,8 +179,8 @@ public class Resilience4jConfigurationPropertiesConfigurer 
extends org.apache.ca
         case "TimeoutDuration": return target.getTimeoutDuration();
         case "timeoutenabled":
         case "TimeoutEnabled": return target.getTimeoutEnabled();
-        case "timeoutexecutorserviceref":
-        case "TimeoutExecutorServiceRef": return 
target.getTimeoutExecutorServiceRef();
+        case "timeoutexecutorservice":
+        case "TimeoutExecutorService": return 
target.getTimeoutExecutorService();
         case "waitdurationinopenstate":
         case "WaitDurationInOpenState": return 
target.getWaitDurationInOpenState();
         case "writablestacktraceenabled":
diff --git 
a/core/camel-main/src/generated/resources/META-INF/camel-main-configuration-metadata.json
 
b/core/camel-main/src/generated/resources/META-INF/camel-main-configuration-metadata.json
index d21cfc3..6b352f8 100644
--- 
a/core/camel-main/src/generated/resources/META-INF/camel-main-configuration-metadata.json
+++ 
b/core/camel-main/src/generated/resources/META-INF/camel-main-configuration-metadata.json
@@ -178,8 +178,8 @@
     { "name": "camel.resilience4j.bulkheadEnabled", "description": "Whether 
bulkhead is enabled or not on the circuit breaker.", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "boolean", 
"javaType": "java.lang.Boolean", "defaultValue": false },
     { "name": "camel.resilience4j.bulkheadMaxConcurrentCalls", "description": 
"Configures the max amount of concurrent calls the bulkhead will support.", 
"sourceType": "org.apache.camel.main.Resilience4jConfigurationProperties", 
"type": "integer", "javaType": "java.lang.Integer" },
     { "name": "camel.resilience4j.bulkheadMaxWaitDuration", "description": 
"Configures a maximum amount of time which the calling thread will wait to 
enter the bulkhead. If bulkhead has space available, entry is guaranteed and 
immediate. If bulkhead is full, calling threads will contest for space, if it 
becomes available. maxWaitDuration can be set to 0. Note: for threads running 
on an event-loop or equivalent (rx computation pool, etc), setting 
maxWaitDuration to 0 is highly recommended [...]
-    { "name": "camel.resilience4j.circuitBreakerRef", "description": "Refers 
to an existing io.github.resilience4j.circuitbreaker.CircuitBreaker instance to 
lookup and use from the registry. When using this, then any other circuit 
breaker options are not in use.", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "string", 
"javaType": "java.lang.String" },
-    { "name": "camel.resilience4j.configRef", "description": "Refers to an 
existing io.github.resilience4j.circuitbreaker.CircuitBreakerConfig instance to 
lookup and use from the registry.", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "string", 
"javaType": "java.lang.String" },
+    { "name": "camel.resilience4j.circuitBreaker", "description": "Refers to 
an existing io.github.resilience4j.circuitbreaker.CircuitBreaker instance to 
lookup and use from the registry. When using this, then any other circuit 
breaker options are not in use.", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "string", 
"javaType": "java.lang.String" },
+    { "name": "camel.resilience4j.config", "description": "Refers to an 
existing io.github.resilience4j.circuitbreaker.CircuitBreakerConfig instance to 
lookup and use from the registry.", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "string", 
"javaType": "java.lang.String" },
     { "name": "camel.resilience4j.failureRateThreshold", "description": 
"Configures the failure rate threshold in percentage. If the failure rate is 
equal or greater than the threshold the CircuitBreaker transitions to open and 
starts short-circuiting calls. The threshold must be greater than 0 and not 
greater than 100. Default value is 50 percentage.", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "number", 
"javaType": "java.lang.Float", "defaultValu [...]
     { "name": "camel.resilience4j.minimumNumberOfCalls", "description": 
"Configures configures the minimum number of calls which are required (per 
sliding window period) before the CircuitBreaker can calculate the error rate. 
For example, if minimumNumberOfCalls is 10, then at least 10 calls must be 
recorded, before the failure rate can be calculated. If only 9 calls have been 
recorded the CircuitBreaker will not transition to open even if all 9 calls 
have failed. Default minimumNumberOf [...]
     { "name": "camel.resilience4j.permittedNumberOfCallsInHalfOpenState", 
"description": "Configures the number of permitted calls when the 
CircuitBreaker is half open. The size must be greater than 0. Default size is 
10.", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "integer", 
"javaType": "java.lang.Integer", "defaultValue": 10 },
@@ -190,7 +190,7 @@
     { "name": "camel.resilience4j.timeoutCancelRunningFuture", "description": 
"Configures whether cancel is called on the running future. Defaults to true.", 
"sourceType": "org.apache.camel.main.Resilience4jConfigurationProperties", 
"type": "boolean", "javaType": "java.lang.Boolean", "defaultValue": true },
     { "name": "camel.resilience4j.timeoutDuration", "description": "Configures 
the thread execution timeout (millis). Default value is 1000 millis (1 
second).", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "integer", 
"javaType": "java.lang.Integer", "defaultValue": 1000 },
     { "name": "camel.resilience4j.timeoutEnabled", "description": "Whether 
timeout is enabled or not on the circuit breaker. Default is false.", 
"sourceType": "org.apache.camel.main.Resilience4jConfigurationProperties", 
"type": "boolean", "javaType": "java.lang.Boolean", "defaultValue": false },
-    { "name": "camel.resilience4j.timeoutExecutorServiceRef", "description": 
"References to a custom thread pool to use when timeout is enabled (uses 
ForkJoinPool#commonPool() by default)", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "string", 
"javaType": "java.lang.String" },
+    { "name": "camel.resilience4j.timeoutExecutorService", "description": 
"References to a custom thread pool to use when timeout is enabled (uses 
ForkJoinPool#commonPool() by default)", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "string", 
"javaType": "java.lang.String" },
     { "name": "camel.resilience4j.waitDurationInOpenState", "description": 
"Configures the wait duration (in seconds) which specifies how long the 
CircuitBreaker should stay open, before it switches to half open. Default value 
is 60 seconds.", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "integer", 
"javaType": "java.lang.Integer", "defaultValue": 60 },
     { "name": "camel.resilience4j.writableStackTraceEnabled", "description": 
"Enables writable stack traces. When set to false, Exception.getStackTrace 
returns a zero length array. This may be used to reduce log spam when the 
circuit breaker is open as the cause of the exceptions is already known (the 
circuit breaker is short-circuiting calls).", "sourceType": 
"org.apache.camel.main.Resilience4jConfigurationProperties", "type": "boolean", 
"javaType": "java.lang.Boolean", "defaultValue":  [...]
     { "name": "camel.rest.apiComponent", "description": "Sets the name of the 
Camel component to use as the REST API (such as swagger or openapi)", 
"sourceType": "org.apache.camel.spi.RestConfiguration", "type": "string", 
"javaType": "java.lang.String" },
diff --git a/core/camel-main/src/main/docs/main.adoc 
b/core/camel-main/src/main/docs/main.adoc
index be20b7c..6505a8b 100644
--- a/core/camel-main/src/main/docs/main.adoc
+++ b/core/camel-main/src/main/docs/main.adoc
@@ -241,8 +241,8 @@ The camel.resilience4j supports 19 options, which are 
listed below.
 | *camel.resilience4j.bulkhead{zwsp}Enabled* | Whether bulkhead is enabled or 
not on the circuit breaker. | false | Boolean
 | *camel.resilience4j.bulkheadMax{zwsp}ConcurrentCalls* | Configures the max 
amount of concurrent calls the bulkhead will support. |  | Integer
 | *camel.resilience4j.bulkheadMax{zwsp}WaitDuration* | Configures a maximum 
amount of time which the calling thread will wait to enter the bulkhead. If 
bulkhead has space available, entry is guaranteed and immediate. If bulkhead is 
full, calling threads will contest for space, if it becomes available. 
maxWaitDuration can be set to 0. Note: for threads running on an event-loop or 
equivalent (rx computation pool, etc), setting maxWaitDuration to 0 is highly 
recommended. Blocking an event-l [...]
-| *camel.resilience4j.circuit{zwsp}BreakerRef* | Refers to an existing 
io.github.resilience4j.circuitbreaker.CircuitBreaker instance to lookup and use 
from the registry. When using this, then any other circuit breaker options are 
not in use. |  | String
-| *camel.resilience4j.configRef* | Refers to an existing 
io.github.resilience4j.circuitbreaker.CircuitBreakerConfig instance to lookup 
and use from the registry. |  | String
+| *camel.resilience4j.circuit{zwsp}Breaker* | Refers to an existing 
io.github.resilience4j.circuitbreaker.CircuitBreaker instance to lookup and use 
from the registry. When using this, then any other circuit breaker options are 
not in use. |  | String
+| *camel.resilience4j.config* | Refers to an existing 
io.github.resilience4j.circuitbreaker.CircuitBreakerConfig instance to lookup 
and use from the registry. |  | String
 | *camel.resilience4j.failureRate{zwsp}Threshold* | Configures the failure 
rate threshold in percentage. If the failure rate is equal or greater than the 
threshold the CircuitBreaker transitions to open and starts short-circuiting 
calls. The threshold must be greater than 0 and not greater than 100. Default 
value is 50 percentage. | 50 | Float
 | *camel.resilience4j.minimum{zwsp}NumberOfCalls* | Configures configures the 
minimum number of calls which are required (per sliding window period) before 
the CircuitBreaker can calculate the error rate. For example, if 
minimumNumberOfCalls is 10, then at least 10 calls must be recorded, before the 
failure rate can be calculated. If only 9 calls have been recorded the 
CircuitBreaker will not transition to open even if all 9 calls have failed. 
Default minimumNumberOfCalls is 100 | 100 | Integer
 | *camel.resilience4j.permitted{zwsp}NumberOfCallsInHalfOpenState* | 
Configures the number of permitted calls when the CircuitBreaker is half open. 
The size must be greater than 0. Default size is 10. | 10 | Integer
@@ -253,7 +253,7 @@ The camel.resilience4j supports 19 options, which are 
listed below.
 | *camel.resilience4j.timeout{zwsp}CancelRunningFuture* | Configures whether 
cancel is called on the running future. Defaults to true. | true | Boolean
 | *camel.resilience4j.timeout{zwsp}Duration* | Configures the thread execution 
timeout (millis). Default value is 1000 millis (1 second). | 1000 | Integer
 | *camel.resilience4j.timeout{zwsp}Enabled* | Whether timeout is enabled or 
not on the circuit breaker. Default is false. | false | Boolean
-| *camel.resilience4j.timeout{zwsp}ExecutorServiceRef* | References to a 
custom thread pool to use when timeout is enabled (uses 
ForkJoinPool#commonPool() by default) |  | String
+| *camel.resilience4j.timeout{zwsp}ExecutorService* | References to a custom 
thread pool to use when timeout is enabled (uses ForkJoinPool#commonPool() by 
default) |  | String
 | *camel.resilience4j.wait{zwsp}DurationInOpenState* | Configures the wait 
duration (in seconds) which specifies how long the CircuitBreaker should stay 
open, before it switches to half open. Default value is 60 seconds. | 60 | 
Integer
 | *camel.resilience4j.writable{zwsp}StackTraceEnabled* | Enables writable 
stack traces. When set to false, Exception.getStackTrace returns a zero length 
array. This may be used to reduce log spam when the circuit breaker is open as 
the cause of the exceptions is already known (the circuit breaker is 
short-circuiting calls). | false | Boolean
 |===
diff --git 
a/core/camel-main/src/main/java/org/apache/camel/main/Resilience4jConfigurationProperties.java
 
b/core/camel-main/src/main/java/org/apache/camel/main/Resilience4jConfigurationProperties.java
index 11b9bf1..d557c49 100644
--- 
a/core/camel-main/src/main/java/org/apache/camel/main/Resilience4jConfigurationProperties.java
+++ 
b/core/camel-main/src/main/java/org/apache/camel/main/Resilience4jConfigurationProperties.java
@@ -30,8 +30,8 @@ public class Resilience4jConfigurationProperties implements 
BootstrapCloseable {
 
     private MainConfigurationProperties parent;
 
-    private String circuitBreakerRef;
-    private String configRef;
+    private String circuitBreaker;
+    private String config;
     @Metadata(defaultValue = "50")
     private Float failureRateThreshold;
     @Metadata(defaultValue = "10")
@@ -56,7 +56,7 @@ public class Resilience4jConfigurationProperties implements 
BootstrapCloseable {
     private Integer bulkheadMaxWaitDuration;
     @Metadata(defaultValue = "false")
     private Boolean timeoutEnabled;
-    private String timeoutExecutorServiceRef;
+    private String timeoutExecutorService;
     @Metadata(defaultValue = "1000")
     private Integer timeoutDuration;
     @Metadata(defaultValue = "true")
@@ -78,28 +78,28 @@ public class Resilience4jConfigurationProperties implements 
BootstrapCloseable {
     // getter and setters
     // --------------------------------------------------------------
 
-    public String getCircuitBreakerRef() {
-        return circuitBreakerRef;
+    public String getCircuitBreaker() {
+        return circuitBreaker;
     }
 
     /**
      * Refers to an existing 
io.github.resilience4j.circuitbreaker.CircuitBreaker instance to lookup and use 
from the
      * registry. When using this, then any other circuit breaker options are 
not in use.
      */
-    public void setCircuitBreakerRef(String circuitBreakerRef) {
-        this.circuitBreakerRef = circuitBreakerRef;
+    public void setCircuitBreaker(String circuitBreaker) {
+        this.circuitBreaker = circuitBreaker;
     }
 
-    public String getConfigRef() {
-        return configRef;
+    public String getConfig() {
+        return config;
     }
 
     /**
      * Refers to an existing 
io.github.resilience4j.circuitbreaker.CircuitBreakerConfig instance to lookup 
and use from
      * the registry.
      */
-    public void setConfigRef(String configRef) {
-        this.configRef = configRef;
+    public void setConfig(String config) {
+        this.config = config;
     }
 
     public Float getFailureRateThreshold() {
@@ -300,16 +300,16 @@ public class Resilience4jConfigurationProperties 
implements BootstrapCloseable {
         this.timeoutEnabled = timeoutEnabled;
     }
 
-    public String getTimeoutExecutorServiceRef() {
-        return timeoutExecutorServiceRef;
+    public String getTimeoutExecutorService() {
+        return timeoutExecutorService;
     }
 
     /**
      * References to a custom thread pool to use when timeout is enabled (uses 
{@link ForkJoinPool#commonPool()} by
      * default)
      */
-    public void setTimeoutExecutorServiceRef(String timeoutExecutorServiceRef) 
{
-        this.timeoutExecutorServiceRef = timeoutExecutorServiceRef;
+    public void setTimeoutExecutorService(String timeoutExecutorService) {
+        this.timeoutExecutorService = timeoutExecutorService;
     }
 
     public Integer getTimeoutDuration() {
@@ -339,7 +339,7 @@ public class Resilience4jConfigurationProperties implements 
BootstrapCloseable {
      * registry. When using this, then any other circuit breaker options are 
not in use.
      */
     public Resilience4jConfigurationProperties withCircuitBreakerRef(String 
circuitBreakerRef) {
-        this.circuitBreakerRef = circuitBreakerRef;
+        this.circuitBreaker = circuitBreakerRef;
         return this;
     }
 
@@ -348,7 +348,7 @@ public class Resilience4jConfigurationProperties implements 
BootstrapCloseable {
      * the registry.
      */
     public Resilience4jConfigurationProperties withConfigRef(String configRef) 
{
-        this.configRef = configRef;
+        this.config = configRef;
         return this;
     }
 
@@ -512,7 +512,7 @@ public class Resilience4jConfigurationProperties implements 
BootstrapCloseable {
      * default)
      */
     public Resilience4jConfigurationProperties 
withTimeoutExecutorServiceRef(String timeoutExecutorServiceRef) {
-        this.timeoutExecutorServiceRef = timeoutExecutorServiceRef;
+        this.timeoutExecutorService = timeoutExecutorServiceRef;
         return this;
     }
 

Reply via email to