You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by gz...@apache.org on 2017/05/31 07:54:32 UTC
[2/3] camel git commit: CAMEL-11335: Retrieve status from
ServiceStatus enum
CAMEL-11335: Retrieve status from ServiceStatus enum
Signed-off-by: Gregor Zurowski <gr...@zurowski.org>
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/8bd0c594
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/8bd0c594
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/8bd0c594
Branch: refs/heads/master
Commit: 8bd0c59429e24be0ca5a33b81f5b5de68ad77a05
Parents: 394c00e
Author: Gregor Zurowski <gr...@zurowski.org>
Authored: Wed May 31 09:25:55 2017 +0200
Committer: Gregor Zurowski <gr...@zurowski.org>
Committed: Wed May 31 09:25:55 2017 +0200
----------------------------------------------------------------------
.../actuate/endpoint/CamelRoutesEndpoint.java | 45 ++------------------
1 file changed, 4 insertions(+), 41 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/8bd0c594/components/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/actuate/endpoint/CamelRoutesEndpoint.java
----------------------------------------------------------------------
diff --git a/components/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/actuate/endpoint/CamelRoutesEndpoint.java b/components/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/actuate/endpoint/CamelRoutesEndpoint.java
index 3cce647..0ccab97 100644
--- a/components/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/actuate/endpoint/CamelRoutesEndpoint.java
+++ b/components/camel-spring-boot/src/main/java/org/apache/camel/spring/boot/actuate/endpoint/CamelRoutesEndpoint.java
@@ -67,17 +67,7 @@ public class CamelRoutesEndpoint extends AbstractEndpoint<List<RouteEndpointInfo
private final long uptimeMillis;
- private Boolean started;
-
- private Boolean starting;
-
- private Boolean stopped;
-
- private Boolean stopping;
-
- private Boolean suspended;
-
- private Boolean suspending;
+ private String serviceStatus;
public RouteEndpointInfo(Route route) {
this.id = route.getId();
@@ -86,13 +76,7 @@ public class CamelRoutesEndpoint extends AbstractEndpoint<List<RouteEndpointInfo
this.uptimeMillis = route.getUptimeMillis();
if (route instanceof StatefulService) {
- StatefulService statefulService = (StatefulService) route;
- this.started = statefulService.isStarted();
- this.starting = statefulService.isStarting();
- this.stopped = statefulService.isStopped();
- this.stopping = statefulService.isStopping();
- this.suspended = statefulService.isSuspended();
- this.suspending = statefulService.isSuspending();
+ this.serviceStatus = ((StatefulService) route).getStatus().name();
}
}
@@ -112,30 +96,9 @@ public class CamelRoutesEndpoint extends AbstractEndpoint<List<RouteEndpointInfo
return uptimeMillis;
}
- public Boolean getStarted() {
- return started;
- }
-
- public Boolean getStarting() {
- return starting;
- }
-
- public Boolean getStopped() {
- return stopped;
- }
-
- public Boolean getStopping() {
- return stopping;
- }
-
- public Boolean getSuspended() {
- return suspended;
- }
-
- public Boolean getSuspending() {
- return suspending;
+ public String getServiceStatus() {
+ return serviceStatus;
}
-
}
}