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 9412fb6b194 Regen
9412fb6b194 is described below
commit 9412fb6b1949afd51de7f033e01987040df9ca40
Author: Claus Ibsen <[email protected]>
AuthorDate: Wed Mar 20 15:54:37 2024 +0100
Regen
---
.../apache/camel/impl/engine/DurationRoutePolicy.java | 9 +++++----
.../camel/impl/engine/DurationRoutePolicyFactory.java | 13 +++++++------
.../camel/throttling/ThrottlingExceptionRoutePolicy.java | 11 ++++++-----
.../camel/throttling/ThrottlingInflightRoutePolicy.java | 16 ++++++++++------
4 files changed, 28 insertions(+), 21 deletions(-)
diff --git
a/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DurationRoutePolicy.java
b/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DurationRoutePolicy.java
index 285439f8b10..0cfce32eaee 100644
---
a/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DurationRoutePolicy.java
+++
b/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DurationRoutePolicy.java
@@ -38,9 +38,9 @@ import org.slf4j.LoggerFactory;
* This can be used to stop the route after it has processed a number of
messages, or has been running for N seconds.
*/
@Metadata(label = "bean",
- description = "RoutePolicy which executes for a duration and then
triggers an action."
- + " This can be used to stop the route after it has
processed a number of messages, or has been running for N seconds.",
- annotations = {"interfaceName=org.apache.camel.spi.RoutePolicy"})
+ description = "RoutePolicy which executes for a duration and then
triggers an action."
+ + " This can be used to stop the route after it has
processed a number of messages, or has been running for N seconds.",
+ annotations = { "interfaceName=org.apache.camel.spi.RoutePolicy" })
@Configurer(metadataOnly = true)
public class DurationRoutePolicy extends
org.apache.camel.support.RoutePolicySupport implements CamelContextAware {
@@ -64,7 +64,8 @@ public class DurationRoutePolicy extends
org.apache.camel.support.RoutePolicySup
private int maxSeconds;
@Metadata(description = "Maximum number of messages to process before the
action is triggered")
private int maxMessages;
- @Metadata(description = "Action to perform", enums =
"STOP_CAMEL_CONTEXT,STOP_ROUTE,SUSPEND_ROUTE,SUSPEND_ALL_ROUTES", defaultValue
= "STOP_ROUTE")
+ @Metadata(description = "Action to perform", enums =
"STOP_CAMEL_CONTEXT,STOP_ROUTE,SUSPEND_ROUTE,SUSPEND_ALL_ROUTES",
+ defaultValue = "STOP_ROUTE")
private Action action = Action.STOP_ROUTE;
public DurationRoutePolicy() {
diff --git
a/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DurationRoutePolicyFactory.java
b/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DurationRoutePolicyFactory.java
index 697d4967f8e..029d12998de 100644
---
a/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DurationRoutePolicyFactory.java
+++
b/core/camel-base-engine/src/main/java/org/apache/camel/impl/engine/DurationRoutePolicyFactory.java
@@ -27,13 +27,13 @@ import org.apache.camel.support.PatternHelper;
/**
* {@link org.apache.camel.spi.RoutePolicyFactory} which executes for a
duration and then triggers an action.
* <p/>
- * This can be used to stop a set of routes (or CamelContext) after they have
processed a number of messages, or has been
- * running for N seconds.
+ * This can be used to stop a set of routes (or CamelContext) after they have
processed a number of messages, or has
+ * been running for N seconds.
*/
@Metadata(label = "bean",
- description = "RoutePolicyFactory which executes for a duration and
then triggers an action."
- + " This can be used to stop a set of routes after they
have processed a number of messages, or has been running for N seconds.",
- annotations =
{"interfaceName=org.apache.camel.spi.RoutePolicyFactory"})
+ description = "RoutePolicyFactory which executes for a duration and
then triggers an action."
+ + " This can be used to stop a set of routes after
they have processed a number of messages, or has been running for N seconds.",
+ annotations = {
"interfaceName=org.apache.camel.spi.RoutePolicyFactory" })
@Configurer(metadataOnly = true)
public class DurationRoutePolicyFactory implements RoutePolicyFactory {
@@ -43,7 +43,8 @@ public class DurationRoutePolicyFactory implements
RoutePolicyFactory {
private int maxSeconds;
@Metadata(description = "Maximum number of messages to process before the
action is triggered")
private int maxMessages;
- @Metadata(description = "Action to perform", enums =
"STOP_CAMEL_CONTEXT,STOP_ROUTE,SUSPEND_ROUTE,SUSPEND_ALL_ROUTES", defaultValue
= "STOP_ROUTE")
+ @Metadata(description = "Action to perform", enums =
"STOP_CAMEL_CONTEXT,STOP_ROUTE,SUSPEND_ROUTE,SUSPEND_ALL_ROUTES",
+ defaultValue = "STOP_ROUTE")
private DurationRoutePolicy.Action action =
DurationRoutePolicy.Action.STOP_ROUTE;
@Override
diff --git
a/core/camel-support/src/main/java/org/apache/camel/throttling/ThrottlingExceptionRoutePolicy.java
b/core/camel-support/src/main/java/org/apache/camel/throttling/ThrottlingExceptionRoutePolicy.java
index 7bf89367fcd..4d5f0d4ad99 100644
---
a/core/camel-support/src/main/java/org/apache/camel/throttling/ThrottlingExceptionRoutePolicy.java
+++
b/core/camel-support/src/main/java/org/apache/camel/throttling/ThrottlingExceptionRoutePolicy.java
@@ -50,9 +50,9 @@ import org.slf4j.LoggerFactory;
* (ie select 1 from dual) to determine if the processes that cause the route
to be open are now available
*/
@Metadata(label = "bean",
- description = "A throttle based RoutePolicy which is modelled after
the circuit breaker and will stop consuming"
- + " from an endpoint based on the type of exceptions
that are thrown and the threshold settings.",
- annotations = {"interfaceName=org.apache.camel.spi.RoutePolicy"})
+ description = "A throttle based RoutePolicy which is modelled after
the circuit breaker and will stop consuming"
+ + " from an endpoint based on the type of exceptions
that are thrown and the threshold settings.",
+ annotations = { "interfaceName=org.apache.camel.spi.RoutePolicy" })
@Configurer(metadataOnly = true)
public class ThrottlingExceptionRoutePolicy extends RoutePolicySupport
implements CamelContextAware {
@@ -76,8 +76,9 @@ public class ThrottlingExceptionRoutePolicy extends
RoutePolicySupport implement
private String exceptions;
private List<Class<?>> throttledExceptions;
// handler for half open circuit can be used instead of resuming route to
check on resources
- @Metadata(label = "advanced", description = "Custom check to perform
whether the circuit breaker can move to half-open state."
- + " If set then this is used
instead of resuming the route.")
+ @Metadata(label = "advanced",
+ description = "Custom check to perform whether the circuit
breaker can move to half-open state."
+ + " If set then this is used instead of resuming
the route.")
private ThrottlingExceptionHalfOpenHandler halfOpenHandler;
// stateful information
diff --git
a/core/camel-support/src/main/java/org/apache/camel/throttling/ThrottlingInflightRoutePolicy.java
b/core/camel-support/src/main/java/org/apache/camel/throttling/ThrottlingInflightRoutePolicy.java
index e94758b6fd0..9cb030b919c 100644
---
a/core/camel-support/src/main/java/org/apache/camel/throttling/ThrottlingInflightRoutePolicy.java
+++
b/core/camel-support/src/main/java/org/apache/camel/throttling/ThrottlingInflightRoutePolicy.java
@@ -53,8 +53,8 @@ import org.slf4j.LoggerFactory;
* {@link #throttle(org.apache.camel.Route, org.apache.camel.Exchange)} when
the current {@link Exchange} is done.
*/
@Metadata(label = "bean",
- description = "A throttle based RoutePolicy which is capable of
dynamic throttling a route based on number of current inflight exchanges.",
- annotations = {"interfaceName=org.apache.camel.spi.RoutePolicy"})
+ description = "A throttle based RoutePolicy which is capable of
dynamic throttling a route based on number of current inflight exchanges.",
+ annotations = { "interfaceName=org.apache.camel.spi.RoutePolicy" })
@Configurer(metadataOnly = true)
public class ThrottlingInflightRoutePolicy extends RoutePolicySupport
implements CamelContextAware {
@@ -69,14 +69,18 @@ public class ThrottlingInflightRoutePolicy extends
RoutePolicySupport implements
private ContextScopedEventNotifier eventNotifier;
private CamelContext camelContext;
private final Lock lock = new ReentrantLock();
- @Metadata(description = "Sets which scope the throttling should be based
upon, either route or total scoped.", enums = "Context,Route", defaultValue =
"Route")
+ @Metadata(description = "Sets which scope the throttling should be based
upon, either route or total scoped.",
+ enums = "Context,Route", defaultValue = "Route")
private ThrottlingScope scope = ThrottlingScope.Route;
- @Metadata(description = "Sets the upper limit of number of concurrent
inflight exchanges at which point reached the throttler should suspend the
route.", defaultValue = "1000")
+ @Metadata(description = "Sets the upper limit of number of concurrent
inflight exchanges at which point reached the throttler should suspend the
route.",
+ defaultValue = "1000")
private int maxInflightExchanges = 1000;
- @Metadata(description = "Sets at which percentage of the max the throttler
should start resuming the route.", defaultValue = "70")
+ @Metadata(description = "Sets at which percentage of the max the throttler
should start resuming the route.",
+ defaultValue = "70")
private int resumePercentOfMax = 70;
private int resumeInflightExchanges = 700;
- @Metadata(description = "Sets the logging level to report the throttling
activity.", javaType = "org.apache.camel.LoggingLevel", defaultValue = "INFO",
enums = "TRACE,DEBUG,INFO,WARN,ERROR,OFF")
+ @Metadata(description = "Sets the logging level to report the throttling
activity.",
+ javaType = "org.apache.camel.LoggingLevel", defaultValue =
"INFO", enums = "TRACE,DEBUG,INFO,WARN,ERROR,OFF")
private LoggingLevel loggingLevel = LoggingLevel.INFO;
private CamelLogger logger;