From 5fc451f98fb4e9013294a328326aac7bd761dfa2 Mon Sep 17 00:00:00 2001 From: lanyuanxiaoyao Date: Wed, 20 Dec 2023 18:09:46 +0800 Subject: [PATCH] =?UTF-8?q?feat(configuration):=20=E5=A2=9E=E5=8A=A0yarn?= =?UTF-8?q?=E7=8A=B6=E6=80=81=E9=9D=99=E6=80=81=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../entity/yarn/YarnApplication.java | 77 ++++++++++++++----- 1 file changed, 56 insertions(+), 21 deletions(-) diff --git a/service-configuration/src/main/java/com/lanyuanxiaoyao/service/configuration/entity/yarn/YarnApplication.java b/service-configuration/src/main/java/com/lanyuanxiaoyao/service/configuration/entity/yarn/YarnApplication.java index f6166cc..ad47ba0 100644 --- a/service-configuration/src/main/java/com/lanyuanxiaoyao/service/configuration/entity/yarn/YarnApplication.java +++ b/service-configuration/src/main/java/com/lanyuanxiaoyao/service/configuration/entity/yarn/YarnApplication.java @@ -116,26 +116,61 @@ public final class YarnApplication { @Override public String toString() { return "YarnApplication{" + - "cluster='" + cluster + '\'' + - ", id='" + id + '\'' + - ", user='" + user + '\'' + - ", queue='" + queue + '\'' + - ", name='" + name + '\'' + - ", state='" + state + '\'' + - ", finalStatus='" + finalStatus + '\'' + - ", progress=" + progress + - ", diagnostics='" + diagnostics + '\'' + - ", applicationType='" + applicationType + '\'' + - ", startedTime=" + startedTime + - ", launchTime=" + launchTime + - ", finishedTime=" + finishedTime + - ", elapsedTime=" + elapsedTime + - ", trackingUrl='" + trackingUrl + '\'' + - ", allocatedMB=" + allocatedMB + - ", allocatedVCores=" + allocatedVCores + - ", runningContainers=" + runningContainers + - ", queueUsagePercentage=" + queueUsagePercentage + - ", clusterUsagePercentage=" + clusterUsagePercentage + - '}'; + "cluster='" + cluster + '\'' + + ", id='" + id + '\'' + + ", user='" + user + '\'' + + ", queue='" + queue + '\'' + + ", name='" + name + '\'' + + ", state='" + state + '\'' + + ", finalStatus='" + finalStatus + '\'' + + ", progress=" + progress + + ", diagnostics='" + diagnostics + '\'' + + ", applicationType='" + applicationType + '\'' + + ", startedTime=" + startedTime + + ", launchTime=" + launchTime + + ", finishedTime=" + finishedTime + + ", elapsedTime=" + elapsedTime + + ", trackingUrl='" + trackingUrl + '\'' + + ", allocatedMB=" + allocatedMB + + ", allocatedVCores=" + allocatedVCores + + ", runningContainers=" + runningContainers + + ", queueUsagePercentage=" + queueUsagePercentage + + ", clusterUsagePercentage=" + clusterUsagePercentage + + '}'; + } + + public static final class State { + /** + * Application which was just created. + */ + public static final String NEW = "NEW"; + /** + * Application which has been submitted. + */ + public static final String NEW_SAVING = "NEW_SAVING"; + /** + * Application which has been submitted. + */ + public static final String SUBMITTED = "SUBMITTED"; + /** + * Application has been accepted by the scheduler + */ + public static final String ACCEPTED = "ACCEPTED"; + /** + * Application which is currently running. + */ + public static final String RUNNING = "RUNNING"; + /** + * Application which finished successfully. + */ + public static final String FINISHED = "FINISHED"; + /** + * Application which failed. + */ + public static final String FAILED = "FAILED"; + /** + * Application which was terminated by a user or admin. + */ + public static final String KILLED = "KILLED"; } }