aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--main/pom.xml2
-rw-r--r--main/src/main/java/org/onap/policy/pap/main/rest/PdpGroupStateChangeProvider.java19
-rw-r--r--packages/policy-pap-docker/pom.xml2
-rw-r--r--packages/policy-pap-tarball/pom.xml2
-rw-r--r--packages/pom.xml2
-rw-r--r--pom.xml8
-rw-r--r--releases/2.2.1-container.yaml8
-rw-r--r--releases/2.2.1.yaml4
-rw-r--r--releases/2.2.2-container.yaml8
-rw-r--r--releases/2.2.2.yaml4
-rw-r--r--testsuites/performance/pom.xml2
-rw-r--r--testsuites/pom.xml2
-rw-r--r--testsuites/stability/pom.xml2
-rw-r--r--version.properties2
14 files changed, 38 insertions, 29 deletions
diff --git a/main/pom.xml b/main/pom.xml
index b0e8ef19..9c3b012e 100644
--- a/main/pom.xml
+++ b/main/pom.xml
@@ -26,7 +26,7 @@
<parent>
<groupId>org.onap.policy.pap</groupId>
<artifactId>policy-pap</artifactId>
- <version>2.2.1-SNAPSHOT</version>
+ <version>2.2.3-SNAPSHOT</version>
</parent>
<artifactId>pap-main</artifactId>
diff --git a/main/src/main/java/org/onap/policy/pap/main/rest/PdpGroupStateChangeProvider.java b/main/src/main/java/org/onap/policy/pap/main/rest/PdpGroupStateChangeProvider.java
index 97a214c7..0c90ae47 100644
--- a/main/src/main/java/org/onap/policy/pap/main/rest/PdpGroupStateChangeProvider.java
+++ b/main/src/main/java/org/onap/policy/pap/main/rest/PdpGroupStateChangeProvider.java
@@ -1,7 +1,7 @@
/*-
* ============LICENSE_START=======================================================
* Copyright (C) 2019 Nordix Foundation.
- * Modifications Copyright (C) 2019 AT&T Intellectual Property.
+ * Modifications Copyright (C) 2019-2020 AT&T Intellectual Property.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -28,7 +28,6 @@ import org.onap.policy.models.base.PfModelException;
import org.onap.policy.models.pap.concepts.PdpGroupStateChangeResponse;
import org.onap.policy.models.pdp.concepts.Pdp;
import org.onap.policy.models.pdp.concepts.PdpGroup;
-import org.onap.policy.models.pdp.concepts.PdpGroupFilter;
import org.onap.policy.models.pdp.concepts.PdpStateChange;
import org.onap.policy.models.pdp.concepts.PdpSubGroup;
import org.onap.policy.models.pdp.concepts.PdpUpdate;
@@ -82,16 +81,10 @@ public class PdpGroupStateChangeProvider extends PdpMessageGenerator {
private void handleActiveState(final String groupName) throws PfModelException {
try (PolicyModelsProvider databaseProvider = modelProviderWrapper.create()) {
- final PdpGroupFilter filter = PdpGroupFilter.builder().name(groupName).groupState(PdpState.ACTIVE).build();
- final List<PdpGroup> activePdpGroups = databaseProvider.getFilteredPdpGroups(filter);
final List<PdpGroup> pdpGroups = databaseProvider.getPdpGroups(groupName);
- if (activePdpGroups.isEmpty() && !pdpGroups.isEmpty()) {
+ if (!pdpGroups.isEmpty() && !PdpState.ACTIVE.equals(pdpGroups.get(0).getPdpGroupState())) {
updatePdpGroupAndPdp(databaseProvider, pdpGroups, PdpState.ACTIVE);
sendPdpMessage(pdpGroups.get(0), PdpState.ACTIVE, databaseProvider);
- } else if (!pdpGroups.isEmpty() && !activePdpGroups.isEmpty()) {
- updatePdpGroupAndPdp(databaseProvider, pdpGroups, PdpState.ACTIVE);
- updatePdpGroup(databaseProvider, activePdpGroups, PdpState.PASSIVE);
- sendPdpMessage(pdpGroups.get(0), PdpState.ACTIVE, databaseProvider);
}
}
}
@@ -106,14 +99,6 @@ public class PdpGroupStateChangeProvider extends PdpMessageGenerator {
}
}
- private void updatePdpGroup(final PolicyModelsProvider databaseProvider, final List<PdpGroup> pdpGroups,
- final PdpState pdpState) throws PfModelException {
- pdpGroups.get(0).setPdpGroupState(pdpState);
- databaseProvider.updatePdpGroups(pdpGroups);
-
- LOGGER.debug("Updated PdpGroup in DB - {} ", pdpGroups);
- }
-
private void updatePdpGroupAndPdp(final PolicyModelsProvider databaseProvider, final List<PdpGroup> pdpGroups,
final PdpState pdpState) throws PfModelException {
pdpGroups.get(0).setPdpGroupState(pdpState);
diff --git a/packages/policy-pap-docker/pom.xml b/packages/policy-pap-docker/pom.xml
index 6b2cb9cd..65aeeed7 100644
--- a/packages/policy-pap-docker/pom.xml
+++ b/packages/policy-pap-docker/pom.xml
@@ -25,7 +25,7 @@
<parent>
<groupId>org.onap.policy.pap</groupId>
<artifactId>pap-packages</artifactId>
- <version>2.2.1-SNAPSHOT</version>
+ <version>2.2.3-SNAPSHOT</version>
</parent>
<artifactId>policy-pap-docker</artifactId>
diff --git a/packages/policy-pap-tarball/pom.xml b/packages/policy-pap-tarball/pom.xml
index 79dc27d6..628a2459 100644
--- a/packages/policy-pap-tarball/pom.xml
+++ b/packages/policy-pap-tarball/pom.xml
@@ -25,7 +25,7 @@
<parent>
<groupId>org.onap.policy.pap</groupId>
<artifactId>pap-packages</artifactId>
- <version>2.2.1-SNAPSHOT</version>
+ <version>2.2.3-SNAPSHOT</version>
</parent>
<artifactId>policy-pap-tarball</artifactId>
diff --git a/packages/pom.xml b/packages/pom.xml
index a09a4f41..1c8c5e92 100644
--- a/packages/pom.xml
+++ b/packages/pom.xml
@@ -26,7 +26,7 @@
<parent>
<groupId>org.onap.policy.pap</groupId>
<artifactId>policy-pap</artifactId>
- <version>2.2.1-SNAPSHOT</version>
+ <version>2.2.3-SNAPSHOT</version>
</parent>
<artifactId>pap-packages</artifactId>
diff --git a/pom.xml b/pom.xml
index e9608d02..90ff0cf3 100644
--- a/pom.xml
+++ b/pom.xml
@@ -26,13 +26,13 @@
<parent>
<groupId>org.onap.policy.parent</groupId>
<artifactId>integration</artifactId>
- <version>3.1.2</version>
+ <version>3.1.3-SNAPSHOT</version>
<relativePath />
</parent>
<groupId>org.onap.policy.pap</groupId>
<artifactId>policy-pap</artifactId>
- <version>2.2.1-SNAPSHOT</version>
+ <version>2.2.3-SNAPSHOT</version>
<packaging>pom</packaging>
@@ -40,8 +40,8 @@
<description>Code that implements the Policy Administration Backend.</description>
<properties>
- <policy.common.version>1.6.4</policy.common.version>
- <policy.models.version>2.2.4</policy.models.version>
+ <policy.common.version>1.6.5-SNAPSHOT</policy.common.version>
+ <policy.models.version>2.2.6-SNAPSHOT</policy.models.version>
</properties>
<modules>
diff --git a/releases/2.2.1-container.yaml b/releases/2.2.1-container.yaml
new file mode 100644
index 00000000..b5a94a88
--- /dev/null
+++ b/releases/2.2.1-container.yaml
@@ -0,0 +1,8 @@
+distribution_type: 'container'
+container_release_tag: '2.2.1'
+project: 'policy-pap'
+log_dir: 'policy-pap-maven-docker-stage-master/27'
+ref: c60f3a48e8e774f56cc02aabb91390c8aa90bce2
+containers:
+ - name: 'policy-pap'
+ version: '2.2.1-20200414T1921'
diff --git a/releases/2.2.1.yaml b/releases/2.2.1.yaml
new file mode 100644
index 00000000..b1b6bd38
--- /dev/null
+++ b/releases/2.2.1.yaml
@@ -0,0 +1,4 @@
+distribution_type: 'maven'
+version: '2.2.1'
+project: 'policy-pap'
+log_dir: 'policy-pap-maven-stage-master/302/'
diff --git a/releases/2.2.2-container.yaml b/releases/2.2.2-container.yaml
new file mode 100644
index 00000000..9876f8c5
--- /dev/null
+++ b/releases/2.2.2-container.yaml
@@ -0,0 +1,8 @@
+distribution_type: 'container'
+container_release_tag: '2.2.2'
+project: 'policy-pap'
+log_dir: 'policy-pap-maven-docker-stage-master/38'
+ref: ab3244b475d55db0e260d338619d688f47c33ea9
+containers:
+ - name: 'policy-pap'
+ version: '2.2.2-20200424T1740'
diff --git a/releases/2.2.2.yaml b/releases/2.2.2.yaml
new file mode 100644
index 00000000..5765bdec
--- /dev/null
+++ b/releases/2.2.2.yaml
@@ -0,0 +1,4 @@
+distribution_type: 'maven'
+version: '2.2.2'
+project: 'policy-pap'
+log_dir: 'policy-pap-maven-stage-master/313/'
diff --git a/testsuites/performance/pom.xml b/testsuites/performance/pom.xml
index 4a713ab3..f20a3de5 100644
--- a/testsuites/performance/pom.xml
+++ b/testsuites/performance/pom.xml
@@ -25,7 +25,7 @@
<parent>
<groupId>org.onap.policy.pap</groupId>
<artifactId>pap-testsuites</artifactId>
- <version>2.2.1-SNAPSHOT</version>
+ <version>2.2.3-SNAPSHOT</version>
</parent>
<artifactId>pap-performance</artifactId>
<build>
diff --git a/testsuites/pom.xml b/testsuites/pom.xml
index 7a714f48..38faccb6 100644
--- a/testsuites/pom.xml
+++ b/testsuites/pom.xml
@@ -23,7 +23,7 @@
<parent>
<groupId>org.onap.policy.pap</groupId>
<artifactId>policy-pap</artifactId>
- <version>2.2.1-SNAPSHOT</version>
+ <version>2.2.3-SNAPSHOT</version>
</parent>
<artifactId>pap-testsuites</artifactId>
diff --git a/testsuites/stability/pom.xml b/testsuites/stability/pom.xml
index 069d3852..6e00fb0f 100644
--- a/testsuites/stability/pom.xml
+++ b/testsuites/stability/pom.xml
@@ -23,7 +23,7 @@
<parent>
<groupId>org.onap.policy.pap</groupId>
<artifactId>pap-testsuites</artifactId>
- <version>2.2.1-SNAPSHOT</version>
+ <version>2.2.3-SNAPSHOT</version>
</parent>
<artifactId>pap-stability</artifactId>
<build>
diff --git a/version.properties b/version.properties
index 71e8e440..a7658aec 100644
--- a/version.properties
+++ b/version.properties
@@ -4,7 +4,7 @@
major=2
minor=2
-patch=1
+patch=3
base_version=${major}.${minor}.${patch}