From f4df1c47c9c6f0ca67d2894b8214108a6bc564ad Mon Sep 17 00:00:00 2001 From: Nikita Tkachenko Date: Fri, 2 Feb 2024 12:49:37 +0100 Subject: [PATCH] Extract VERSION constant --- .../jenkins/plugins/datadog/model/GitCommitAction.java | 5 ++++- .../jenkins/plugins/datadog/model/GitRepositoryAction.java | 5 ++++- .../plugins/datadog/model/PipelineNodeInfoAction.java | 5 ++++- .../plugins/datadog/model/PipelineQueueInfoAction.java | 5 ++++- .../jenkins/plugins/datadog/model/TraceInfoAction.java | 5 ++++- .../jenkins/plugins/datadog/model/node/DequeueAction.java | 5 ++++- .../jenkins/plugins/datadog/model/node/EnqueueAction.java | 5 ++++- .../jenkins/plugins/datadog/model/node/NodeInfoAction.java | 5 ++++- .../jenkins/plugins/datadog/model/node/StatusAction.java | 5 ++++- .../jenkins/plugins/datadog/traces/BuildSpanAction.java | 5 ++++- .../jenkins/plugins/datadog/traces/message/TraceSpan.java | 5 ++++- 11 files changed, 44 insertions(+), 11 deletions(-) diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/model/GitCommitAction.java b/src/main/java/org/datadog/jenkins/plugins/datadog/model/GitCommitAction.java index c88bf819..6997a377 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/model/GitCommitAction.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/model/GitCommitAction.java @@ -148,8 +148,11 @@ public ConverterImpl(XStream xs) { } public static final class ConverterV1 extends VersionedConverter { + + private static final int VERSION = 1; + public ConverterV1() { - super(1); + super(VERSION); } @Override diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/model/GitRepositoryAction.java b/src/main/java/org/datadog/jenkins/plugins/datadog/model/GitRepositoryAction.java index a356b245..048217a5 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/model/GitRepositoryAction.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/model/GitRepositoryAction.java @@ -86,8 +86,11 @@ public ConverterImpl(XStream xs) { } public static final class ConverterV1 extends VersionedConverter { + + private static final int VERSION = 1; + public ConverterV1() { - super(1); + super(VERSION); } @Override diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/model/PipelineNodeInfoAction.java b/src/main/java/org/datadog/jenkins/plugins/datadog/model/PipelineNodeInfoAction.java index b5fb3dda..b598c11d 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/model/PipelineNodeInfoAction.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/model/PipelineNodeInfoAction.java @@ -71,8 +71,11 @@ public ConverterImpl(XStream xs) { } public static final class ConverterV1 extends VersionedConverter { + + private static final int VERSION = 1; + public ConverterV1() { - super(1); + super(VERSION); } @Override diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/model/PipelineQueueInfoAction.java b/src/main/java/org/datadog/jenkins/plugins/datadog/model/PipelineQueueInfoAction.java index 8d168aee..2c753c93 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/model/PipelineQueueInfoAction.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/model/PipelineQueueInfoAction.java @@ -69,8 +69,11 @@ public ConverterImpl(XStream xs) { } public static final class ConverterV1 extends VersionedConverter { + + private static final int VERSION = 1; + public ConverterV1() { - super(1); + super(VERSION); } @Override diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/model/TraceInfoAction.java b/src/main/java/org/datadog/jenkins/plugins/datadog/model/TraceInfoAction.java index 644fe99a..141e29d1 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/model/TraceInfoAction.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/model/TraceInfoAction.java @@ -86,8 +86,11 @@ public ConverterImpl(XStream xs) { } public static final class ConverterV1 extends VersionedConverter { + + private static final int VERSION = 1; + public ConverterV1() { - super(1); + super(VERSION); } @Override diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/DequeueAction.java b/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/DequeueAction.java index df1f589d..7bd3a45f 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/DequeueAction.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/DequeueAction.java @@ -48,8 +48,11 @@ public ConverterImpl(XStream xs) { } public static final class ConverterV1 extends VersionedConverter { + + private static final int VERSION = 1; + public ConverterV1() { - super(1); + super(VERSION); } @Override diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/EnqueueAction.java b/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/EnqueueAction.java index 34dfec36..f1f4af46 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/EnqueueAction.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/EnqueueAction.java @@ -48,8 +48,11 @@ public ConverterImpl(XStream xs) { } public static final class ConverterV1 extends VersionedConverter { + + private static final int VERSION = 1; + public ConverterV1() { - super(1); + super(VERSION); } @Override diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/NodeInfoAction.java b/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/NodeInfoAction.java index 4d2aceb0..8aed8ddc 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/NodeInfoAction.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/NodeInfoAction.java @@ -74,8 +74,11 @@ public ConverterImpl(XStream xs) { } public static final class ConverterV1 extends VersionedConverter { + + private static final int VERSION = 1; + public ConverterV1() { - super(1); + super(VERSION); } @Override diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/StatusAction.java b/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/StatusAction.java index 58d9038f..0a254463 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/StatusAction.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/model/node/StatusAction.java @@ -59,8 +59,11 @@ public ConverterImpl(XStream xs) { } public static final class ConverterV1 extends VersionedConverter { + + private static final int VERSION = 1; + public ConverterV1() { - super(1); + super(VERSION); } @Override diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/traces/BuildSpanAction.java b/src/main/java/org/datadog/jenkins/plugins/datadog/traces/BuildSpanAction.java index a546ff3d..ea99115a 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/traces/BuildSpanAction.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/traces/BuildSpanAction.java @@ -71,8 +71,11 @@ public ConverterImpl(XStream xs) { } public static final class ConverterV1 extends VersionedConverter { + + private static final int VERSION = 1; + public ConverterV1() { - super(1); + super(VERSION); } @Override diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/traces/message/TraceSpan.java b/src/main/java/org/datadog/jenkins/plugins/datadog/traces/message/TraceSpan.java index b8177e22..26ee310c 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/traces/message/TraceSpan.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/traces/message/TraceSpan.java @@ -189,8 +189,11 @@ public ConverterImpl(XStream xs) { } public static final class ConverterV1 extends VersionedConverter { + + private static final int VERSION = 1; + public ConverterV1() { - super(1); + super(VERSION); } @Override