From: AndyWalshe Date: Thu, 12 Mar 2020 15:57:39 +0000 (+0000) Subject: Commit pnf deletion to database in PMSH X-Git-Tag: 1.0.1^0 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F23%2F103623%2F2;p=dcaegen2%2Fservices.git Commit pnf deletion to database in PMSH Issue-ID: DCAEGEN2-2142 Signed-off-by: AndyWalshe Change-Id: Ib4945174aec490d1149903c01f64fc5dd5e19496 --- diff --git a/components/pm-subscription-handler/pmsh_service/mod/network_function.py b/components/pm-subscription-handler/pmsh_service/mod/network_function.py index c4b9b56c..2150dc28 100755 --- a/components/pm-subscription-handler/pmsh_service/mod/network_function.py +++ b/components/pm-subscription-handler/pmsh_service/mod/network_function.py @@ -82,4 +82,6 @@ class NetworkFunction: nf = NetworkFunctionModel.query.filter( NetworkFunctionModel.nf_name == nf_name).one_or_none() - db.session.delete(nf) if nf else None + if nf: + db.session.delete(nf) + db.session.commit() diff --git a/components/pm-subscription-handler/pom.xml b/components/pm-subscription-handler/pom.xml index 74ad400f..04d6fac4 100644 --- a/components/pm-subscription-handler/pom.xml +++ b/components/pm-subscription-handler/pom.xml @@ -31,7 +31,7 @@ org.onap.dcaegen2.services pmsh dcaegen2-services-pm-subscription-handler - 1.0.0-SNAPSHOT + 1.0.1-SNAPSHOT UTF-8 . diff --git a/components/pm-subscription-handler/version.properties b/components/pm-subscription-handler/version.properties index 2ddebb39..0f1f46a5 100644 --- a/components/pm-subscription-handler/version.properties +++ b/components/pm-subscription-handler/version.properties @@ -1,6 +1,6 @@ major=1 minor=0 -patch=0 +patch=1 base_version=${major}.${minor}.${patch} release_version=${base_version} snapshot_version=${base_version}-SNAPSHOT