policy/models.git
4 years agoDesign Operational Policy Type for Apex 48/101048/2
a.sreekumar [Fri, 31 Jan 2020 14:30:29 +0000 (14:30 +0000)]
Design Operational Policy Type for Apex

Design the TOSCA Policy Type for operational policy supported by Apex
so that CLAMP can select this policy type for control loops that are designed to use Apex.

Change-Id: I50099a47d5314fa42e353856715adaaa20352a96
Issue-ID: POLICY-2147
Signed-off-by: a.sreekumar <ajith.sreekumar@est.tech>
4 years agoMerge "Add service template persistence provider"
Jorge Hernandez [Tue, 28 Jan 2020 16:35:34 +0000 (16:35 +0000)]
Merge "Add service template persistence provider"

4 years agoAdd service template persistence provider 38/100838/4
liamfallon [Tue, 28 Jan 2020 00:33:25 +0000 (19:33 -0500)]
Add service template persistence provider

Persistence needs to be carried out at service template level in order
to guarantee consistency of the service template in the database as much
as possible. Therefire, service template lelve reading, writing, and
delting is required.

Issue-ID: POLICY-1402
Change-Id: I5be57c29381bf6ddc87afdbb64ddae66a5ea5e5f
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoHandling supported policy type during PdpGroup Update 80/100680/1
a.sreekumar [Thu, 23 Jan 2020 13:35:07 +0000 (13:35 +0000)]
Handling supported policy type during PdpGroup Update

Change-Id: I62fbfeb80b81f4cc6dc0049bbd4ab9dcc5065773
Issue-ID: POLICY-2023
Signed-off-by: a.sreekumar <ajith.sreekumar@est.tech>
4 years agoHandling supported policy type during PdpGroup Update 94/100594/4
a.sreekumar [Tue, 21 Jan 2020 17:07:50 +0000 (17:07 +0000)]
Handling supported policy type during PdpGroup Update

Change-Id: I469125c232af9d78a55c3dfa71cb701cb3864015
Issue-ID: POLICY-2023
Signed-off-by: a.sreekumar <ajith.sreekumar@est.tech>
4 years agovcpe operational policy tosca compliant json 20/100520/3
jhh [Mon, 20 Jan 2020 23:21:35 +0000 (17:21 -0600)]
vcpe operational policy tosca compliant json

Issue-ID: POLICY-2148
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
Change-Id: Id8ac0279184e5d063cbff197e47f14745a9ef353
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
4 years agoUpdate Dockerfiles for java11 in policy-models 16/100416/4
Jim Hahn [Fri, 17 Jan 2020 15:14:40 +0000 (10:14 -0500)]
Update Dockerfiles for java11 in policy-models

Also modified docker build scripts so they work with SNAPSHOT
or release versions of the tarballs.

Issue-ID: POLICY-1586
Signed-off-by: Jim Hahn <jrh3@att.com>
Change-Id: Ib5b8c0b83d7736180ab213b0b67d457eab7ee48e

4 years agoMerge "Ensure one jacoco output file"
Jorge Hernandez [Thu, 16 Jan 2020 17:36:30 +0000 (17:36 +0000)]
Merge "Ensure one jacoco output file"

4 years agoEnsure one jacoco output file 84/100384/1
Pamela Dragosh [Thu, 16 Jan 2020 16:55:29 +0000 (11:55 -0500)]
Ensure one jacoco output file

Sub-modules under sub-modules need to set the path to
ensure a single jacoco-ut.exec file is produced and
appended to.

I think this only gives us .1% - but that's ok. Its a
step towards consolidation.

Issue-ID: POLICY-2321
Change-Id: I31023843f55200096a905482ee55ad19bf681494
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
4 years agoMerge "Added Time agnostic Onset and Abated classes"
Jorge Hernandez [Thu, 16 Jan 2020 15:22:26 +0000 (15:22 +0000)]
Merge "Added Time agnostic Onset and Abated classes"

4 years agoAdded Time agnostic Onset and Abated classes 00/100300/4
jhh [Wed, 15 Jan 2020 04:48:45 +0000 (22:48 -0600)]
Added Time agnostic Onset and Abated classes

These classes can be used for comparison of alarm skeletons
independently of the time at which they were produced.

Issue-ID: POLICY-2323
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
Change-Id: I85b9d6a429de56f056eb0a6caa9e4f90fbd68918
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
4 years agoMerge "Clean up TOSCA provider unit tests"
Pamela Dragosh [Thu, 16 Jan 2020 13:44:40 +0000 (13:44 +0000)]
Merge "Clean up TOSCA provider unit tests"

4 years agoClean up TOSCA provider unit tests 05/100305/3
liamfallon [Wed, 15 Jan 2020 08:20:05 +0000 (09:20 +0100)]
Clean up TOSCA provider unit tests

SOme outstanding comment on TOSCA provider unit tests cleaned up.

Issue-ID: POLICY-2315
Change-Id: I235a5fc9996c81f421f17236afb413df7435de19
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoUpdate sonar config 93/100293/1
Pamela Dragosh [Tue, 14 Jan 2020 19:24:20 +0000 (14:24 -0500)]
Update sonar config

Skip module that doesn't have code.
parent now defines the plugins, no need to duplicate
that.

Issue-ID: POLICY-2321
Change-Id: I84a161781cc0b44ba8d328ff5fb269855fcc4b36
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
4 years agoRead resource dirs in models prvider unit tests 37/100237/2
liamfallon [Sun, 12 Jan 2020 17:49:25 +0000 (17:49 +0000)]
Read resource dirs in models prvider unit tests

Update the unit tests in models-provider so that we can check that the
TOSCA artifact that is read from the database is the same as the TOSCA
artifact that is stored.

This review does some groundwork for that check.

Issue-ID: POLICY-2315
Change-Id: Iabc7b247736b862713585a493752bc254cfe1c3d
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoRemove deprecated methods from models 28/100228/3
Jim Hahn [Fri, 10 Jan 2020 22:52:57 +0000 (17:52 -0500)]
Remove deprecated methods from models

Addressed the following issues related to the java 11 upgrade:
- forClass().newInstance()
- java.xml.bind no longer included in jdk
- new mockito doesn't clear captured lists

Issue-ID: POLICY-1406
Signed-off-by: Jim Hahn <jrh3@att.com>
Change-Id: Ia254c1ed21f847d1824e7abc22528975372ee2b6

4 years agopolicy/models jdk 11 upgrades 73/99873/8
HOCKLA [Sat, 21 Dec 2019 18:11:33 +0000 (12:11 -0600)]
policy/models jdk 11 upgrades

Issue-ID: POLICY-1592
Change-Id: Iaa6b61c5f1c76f3e7c2043691f4d29dbc43d144e
Signed-off-by: HOCKLA <ah999m@att.com>
4 years agoBumped patch version for policy/models 05/100205/3
HOCKLA [Fri, 10 Jan 2020 18:16:00 +0000 (12:16 -0600)]
Bumped patch version for policy/models

Issue-ID: POLICY-1592
Change-Id: Iafc35fe53e28c815a79041f289cb17b6354ceccd
Signed-off-by: HOCKLA <ah999m@att.com>
4 years agoRelease policy/models 2.2.0 03/100203/1
HOCKLA [Fri, 10 Jan 2020 17:31:09 +0000 (11:31 -0600)]
Release policy/models 2.2.0

Issue-ID: POLICY-1592
Change-Id: I751dbafc67d5f232e930b56f8399ea326c6efdb1
Signed-off-by: HOCKLA <ah999m@att.com>
4 years agoMerge "Added new policy examples to support integration of new version validation...
Liam Fallon [Fri, 10 Jan 2020 15:37:41 +0000 (15:37 +0000)]
Merge "Added new policy examples to support integration of new version validation feature"

4 years agoMerge "Remove supportedPolicyTypes from PdpStatus"
Liam Fallon [Fri, 10 Jan 2020 15:35:58 +0000 (15:35 +0000)]
Merge "Remove supportedPolicyTypes from PdpStatus"

4 years agoMerge "Remove ControlLoopParams."
Pamela Dragosh [Fri, 10 Jan 2020 15:00:13 +0000 (15:00 +0000)]
Merge "Remove ControlLoopParams."

4 years agoAdded new policy examples to support integration of new version validation feature 47/100147/4
Chenfei Gao [Thu, 9 Jan 2020 19:04:05 +0000 (14:04 -0500)]
Added new policy examples to support integration of new version validation feature

Issue-ID: POLICY-2316
Change-Id: Ifcb6739c7dd6c5796067a4b9e2f3eef960e1ace4
Signed-off-by: Chenfei Gao <cgao@research.att.com>
4 years agoFix policy-models to support data type properties 86/100186/1
liamfallon [Fri, 10 Jan 2020 13:57:29 +0000 (13:57 +0000)]
Fix policy-models to support data type properties

Data type properties are not being stored correctly into the database
when MariaDB is used (it worked fine in unit tests in H2).

Issue-ID: POLICY-2315
Change-Id: Ia901a070292b338154f3766f5fc7b91d656038df
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoRemove supportedPolicyTypes from PdpStatus 83/100183/2
ramverma [Fri, 10 Jan 2020 10:46:40 +0000 (10:46 +0000)]
Remove supportedPolicyTypes from PdpStatus

Removing supportedPolicyTypes from PdpStatus in policy/models as it is
no longer expected from the Pdps to send it as part of the heartbeat or
initial registration message. Instead the PdpGroupName is expected from
the Pdps in the initial registration message.

Issue-ID: POLICY-2256
Change-Id: I14b76a737027e146d69d89c2fe2c3f098a89e196
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
4 years agoRemove ControlLoopParams. 66/100166/1
jhh [Thu, 9 Jan 2020 23:49:31 +0000 (17:49 -0600)]
Remove ControlLoopParams.

This class is only useful in drools-applications repo.

Issue-ID: POLICY-2146
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
Change-Id: Ifbf281a3742950c3cad2c5b56689122dd766b41a

4 years agoMerge "Update tosca utils to remove code duplication"
Jim Hahn [Thu, 9 Jan 2020 14:33:29 +0000 (14:33 +0000)]
Merge "Update tosca utils to remove code duplication"

4 years agoMerge "update Db provider to support query number"
Jim Hahn [Thu, 9 Jan 2020 13:58:02 +0000 (13:58 +0000)]
Merge "update Db provider to support query number"

4 years agoUpdate tosca utils to remove code duplication 02/100102/1
liamfallon [Wed, 8 Jan 2020 17:04:50 +0000 (17:04 +0000)]
Update tosca utils to remove code duplication

Refactored the ToscaUtils class to remove code duplication.

Issue-ID: POLICY-2315
Change-Id: Ic06a0881d1797dbb3c45ae1903a150fbda421e72
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoStore and return data types for policies 64/100064/2
liamfallon [Tue, 7 Jan 2020 18:26:53 +0000 (18:26 +0000)]
Store and return data types for policies

In this change, the data types of policy types are persisted to the
database. All policy types currently in the database are returned on all
policy type get requests. This will be made more intelligent in the next
review.

Issue-ID: POLICY-2315
Change-Id: I10065ab9b90e72114a453494fc706d8aabc50c0a
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoupdate Db provider to support query number 17/99917/6
ning.xi [Thu, 26 Dec 2019 13:37:52 +0000 (21:37 +0800)]
update Db provider to support query number

Issue-ID: POLICY-1629
Signed-off-by: ning.xi <ning.xi@est.tech>
Change-Id: I42c9542adc44d52b760a70e710ab4cc6fa8a1b3b

4 years agoSupport persistence of data types 44/100044/4
liamfallon [Tue, 7 Jan 2020 10:24:12 +0000 (10:24 +0000)]
Support persistence of data types

Data types must be persisted to the database in order for them to be
retrieved in policy type queries and later for policy validation.

Issue-ID: POLICY-2315
Change-Id: Iacb88501a597aeee8f6d8bcc3d9604c13dc09090
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoMerge "pdp statistics database provider implementation"
Liam Fallon [Mon, 23 Dec 2019 20:18:31 +0000 (20:18 +0000)]
Merge "pdp statistics database provider implementation"

4 years agopdp statistics database provider implementation 68/99468/9
ning.xi [Wed, 11 Dec 2019 07:55:59 +0000 (15:55 +0800)]
pdp statistics database provider implementation

Issue-ID: POLICY-1629
Signed-off-by: ning.xi <ning.xi@est.tech>
Change-Id: Ife65d50c862ed90c3c9a3cea91a2b9a8d874fa14

4 years agoModifications to decision request and policy fixes 78/99678/2
Pamela Dragosh [Mon, 16 Dec 2019 16:11:05 +0000 (11:11 -0500)]
Modifications to decision request and policy fixes

Discovered while working on both the SDNC naming and
optimization application work.

Fixed the datatype for SDNC naming policy type
Added a copy constructor for Decision request
Added metadata for optimization Subscriber policy type

Issue-ID: POLICY-2066
Change-Id: I83c99533f26747c856c591d05d22691714549cf2
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
4 years agoFix timeout bug in dmaap simulator 04/99504/2
Jim Hahn [Wed, 11 Dec 2019 16:32:01 +0000 (11:32 -0500)]
Fix timeout bug in dmaap simulator

Also added a start script that can be used to execute the simulator
in stand-alone mode (i.e., outside of a docker container).

Change-Id: I26550ad36cfd2448c96cf0c09fec24e60ffd815b
Issue-ID: POLICY-2298
Signed-off-by: Jim Hahn <jrh3@att.com>
4 years agoMerge "Fix minor checksyle issues in models"
Pamela Dragosh [Wed, 11 Dec 2019 14:47:53 +0000 (14:47 +0000)]
Merge "Fix minor checksyle issues in models"

4 years agoMerge "Update optimization policies"
Jim Hahn [Wed, 11 Dec 2019 13:34:39 +0000 (13:34 +0000)]
Merge "Update optimization policies"

4 years agoUpdate optimization policies 39/99439/2
Pamela Dragosh [Tue, 10 Dec 2019 18:47:55 +0000 (13:47 -0500)]
Update optimization policies

These policies need to be updated.

Issue-ID: POLICY-2066
Change-Id: Idc15aa36f4295477b37aa6398920853436909751
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
4 years agoFix minor checksyle issues in models 12/99412/1
liamfallon [Tue, 10 Dec 2019 13:57:32 +0000 (13:57 +0000)]
Fix minor checksyle issues in models

New checkstyle profile flagged some minor issues in policy models.

Issue-ID: POLICY-2165
Change-Id: I17ed070a3d55601ad31e48fdfd29fff01d29fa42
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoMerge "Add JpaPdpStatistics entity"
Ram Krishna Verma [Tue, 10 Dec 2019 09:44:19 +0000 (09:44 +0000)]
Merge "Add JpaPdpStatistics entity"

4 years agoMerge "Add type_version to naming policy"
Ram Krishna Verma [Mon, 9 Dec 2019 15:58:06 +0000 (15:58 +0000)]
Merge "Add type_version to naming policy"

4 years agoMerge "Refactor optimization policies"
Pamela Dragosh [Mon, 9 Dec 2019 15:31:20 +0000 (15:31 +0000)]
Merge "Refactor optimization policies"

4 years agoAdd JpaPdpStatistics entity 39/97939/9
shaoqiu [Fri, 8 Nov 2019 03:09:08 +0000 (11:09 +0800)]
Add JpaPdpStatistics entity

Add JpaPdpStatistics entity which will be used in provider.
Add Pdp Statistics entities

Issue-ID: POLICY-1628
Signed-off-by: shaoqiu <tim.huang@est.tech>
Change-Id: Iab12eb02e2e7f0e366aff64fa665b5d6674f2905
Signed-off-by: shaoqiu <tim.huang@est.tech>
4 years agoAdd type_version to naming policy 02/99302/2
Pamela Dragosh [Sun, 8 Dec 2019 22:43:30 +0000 (17:43 -0500)]
Add type_version to naming policy

For testing purposes in the xacml-pdp JUnits.

Issue-ID: POLICY-1740
Change-Id: Ia35583b5aac6a40f62542b907d7f3358fc1bcbcd
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
4 years agoRefactor optimization policies 88/99288/2
Pamela Dragosh [Sat, 7 Dec 2019 23:00:36 +0000 (18:00 -0500)]
Refactor optimization policies

Optimization policies need to be further refactored so
that Resource vs Service type policies can be specified.

Issue-ID: POLICY-2066
Change-Id: Ia40a947097692ea7dcc6ea8d13eb8669c37fac14
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
4 years agoAdd models to support deltas to policy deployments 80/99280/2
Jim Hahn [Fri, 6 Dec 2019 15:22:48 +0000 (10:22 -0500)]
Add models to support deltas to policy deployments

Change-Id: Ia5134e2ba4faeefe8bcc1333abe6acc57972c243
Issue-ID: POLICY-2274
Signed-off-by: Jim Hahn <jrh3@att.com>
4 years agoPoint to new release version 1.6.1 policy/common 75/99275/1
HOCKLA [Fri, 6 Dec 2019 17:46:24 +0000 (11:46 -0600)]
Point to new release version 1.6.1 policy/common

Issue-ID: POLICY-1583
Change-Id: I63b7f3934b9d6e26400c0dd68e5e31b533be1881
Signed-off-by: HOCKLA <ah999m@att.com>
4 years agoMerge "Add new Operational Policy Type"
Jorge Hernandez [Fri, 6 Dec 2019 15:07:03 +0000 (15:07 +0000)]
Merge "Add new Operational Policy Type"

4 years agoAdd new Operational Policy Type 65/97965/11
Pamela Dragosh [Tue, 5 Nov 2019 14:35:30 +0000 (09:35 -0500)]
Add new Operational Policy Type

New operational policy type for Frankfurt. Updating examples.

added sample CLAMP metadata.

Issue-ID: POLICY-2217
Change-Id: I941c3a4187a4d164bf793ef2d82c34fccc1a2c35
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
4 years agoUpdated pom.xml to point to release versions of policy/parent and policy/common 17/99217/1
HOCKLA [Thu, 5 Dec 2019 16:24:14 +0000 (10:24 -0600)]
Updated pom.xml to point to release versions of policy/parent and policy/common

Issue-ID: POLICY-1594/POLICY-1583
Change-Id: Ib8280ab847d8a81d8470c4f4600a6b2a626ae28b
Signed-off-by: HOCKLA <ah999m@att.com>
4 years agoAdding Response model class for PdpGroup Create/Update operation 63/99163/1
a.sreekumar [Wed, 4 Dec 2019 16:40:50 +0000 (16:40 +0000)]
Adding Response model class for PdpGroup Create/Update operation

Change-Id: Ifa3b4c1e51a1446f47adf8d263989440bddfa8b9
Issue-ID: POLICY-2273
Signed-off-by: a.sreekumar <ajith.sreekumar@est.tech>
4 years agoAdding native policy type for apex-pdp 28/99128/1
ramverma [Wed, 4 Dec 2019 09:41:01 +0000 (09:41 +0000)]
Adding native policy type for apex-pdp

Issue-ID: POLICY-2279
Change-Id: Icf9fc690aa885c490ada40b4ad8c6ea1a5fe8586
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
4 years agoMerge "Reduce volume of log information on A&AI calls"
Ram Krishna Verma [Thu, 28 Nov 2019 14:24:22 +0000 (14:24 +0000)]
Merge "Reduce volume of log information on A&AI calls"

4 years agoReduce volume of log information on A&AI calls 74/98774/4
liamfallon [Fri, 22 Nov 2019 17:28:02 +0000 (17:28 +0000)]
Reduce volume of log information on A&AI calls

The AaiManager class is logging all the http requests and responses to
and from A&AI to logger.info, creating a large volume of logging text,
the logging of these messages is now set logger.debug, so they are off
by default but can be enabled for debugging.

Issue-ID: POLICY-2125
Change-Id: I5f9674db0f9e5b271606e7af34d5218f5c629b09
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoCDS actor payload to be JSON object when applicable 18/98818/3
Rashmi Pujar [Mon, 25 Nov 2019 17:56:24 +0000 (12:56 -0500)]
CDS actor payload to be JSON object when applicable

When the policy-payload supplied by CLAMP is a valid JSON string
the CDS Blueprint payload must be a JSON object, else retain the
CDS Blueprint payload to be a string.

Issue-ID: POLICY-2253
Signed-off-by: Rashmi Pujar <rashmi.pujar@bell.ca>
Change-Id: I6380ab0424339603ecf52d298e4f6f0cd8df754b

4 years agoUse dependency management for cds proto-definition artifact 16/98816/1
Rashmi Pujar [Mon, 25 Nov 2019 16:00:52 +0000 (11:00 -0500)]
Use dependency management for cds proto-definition artifact

Refer to: https://gerrit.onap.org/r/#/c/policy/parent/+/98733/

Issue-ID: POLICY-2254
Signed-off-by: Rashmi Pujar <rashmi.pujar@bell.ca>
Change-Id: Ie1053ee05f68e8b06bae20c4ce8514dd3aa21d33

4 years agoMerge "Added new policy types for native PDP policies"
Jim Hahn [Fri, 22 Nov 2019 14:20:55 +0000 (14:20 +0000)]
Merge "Added new policy types for native PDP policies"

4 years agoAllow wild cards in supported type filter 38/98738/2
Jim Hahn [Thu, 21 Nov 2019 19:59:52 +0000 (14:59 -0500)]
Allow wild cards in supported type filter

PAP was rejecting deployment of policies whose supported type
contained a wild card.  This was due to the fact that it was
querying the Pdp Groups using a filter on the supported type,
which did not take wild cards into consideration.  Updated the
filtering.

Change-Id: I50b3202a00ac85ff09a9861d8bbe1efb6dd49ae3
Issue-ID: POLICY-1636
Signed-off-by: Jim Hahn <jrh3@att.com>
4 years agoAdded new policy types for native PDP policies 70/98370/10
Chenfei Gao [Wed, 13 Nov 2019 15:45:21 +0000 (10:45 -0500)]
Added new policy types for native PDP policies

Issue-ID: POLICY-2212
Change-Id: Ib29ad66994aa64a73f23bc36eebbc1bc03b2ac02
Signed-off-by: Chenfei Gao <cgao@research.att.com>
4 years agoFix minor checkstyle issuse in models A&AI 15/98715/1
liamfallon [Thu, 21 Nov 2019 13:59:07 +0000 (13:59 +0000)]
Fix minor checkstyle issuse in models A&AI

Some minor checkstyle issues in the policy models Custom Query support
in A&AI fixed.

Issue-ID: POLICY-2125
Change-Id: I520caa044966acbe28d3cd864b53fb398df2f385
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoSupport wild cards in "supported policy types" 76/98476/3
Jim Hahn [Fri, 15 Nov 2019 19:12:23 +0000 (14:12 -0500)]
Support wild cards in "supported policy types"

Refactored PfConceptKey, extracting most of it into PfKeyImpl.
Added PfSearchableKey as a subclass of PfKeyImpl.

Change-Id: I524f4ce9208fc9ba09e77db4cc7dde5a21e1d7fc
Issue-ID: POLICY-2224
Signed-off-by: Jim Hahn <jrh3@att.com>
4 years agoMerge "Removing Named Query."
Pamela Dragosh [Fri, 15 Nov 2019 14:18:05 +0000 (14:18 +0000)]
Merge "Removing Named Query."

4 years agoRemoving Named Query. 82/98382/2
pramod.jamkhedkar [Wed, 13 Nov 2019 18:21:16 +0000 (13:21 -0500)]
Removing Named Query.

Removing all the related  files and necessary modifications for removing named query. The code now only supports Custom Query

Issue-ID: POLICY-2125
Change-Id: Ifa5ccb74142aa424359c0dea85b90bbcf70147cb
Signed-off-by: pramod.jamkhedkar <pramod@research.att.com>
4 years agoRemove duplicate dao object 79/98379/1
Jim Hahn [Wed, 13 Nov 2019 18:05:58 +0000 (13:05 -0500)]
Remove duplicate dao object

Code was creating the DAO object twice - removed the extra line.
Note: this properly doesn't fix the race condition, but it should fix
a memory leak.

Change-Id: I5f5c6002d42f9bb0525d1b5013b1300e80264645
Issue-ID: POLICY-1832
Signed-off-by: Jim Hahn <jrh3@att.com>
4 years agoFix sonar issue affecting in drools-applications 87/98187/1
Jim Hahn [Fri, 8 Nov 2019 14:17:42 +0000 (09:17 -0500)]
Fix sonar issue affecting in drools-applications

Drools-applications has a serializable class that contains AaiCqResponse.
Sonar complained that the latter class must also be serializable, so
made the change in policy-models to fix that.  In addition, the latter
class contained a list of Object.  To ensure that those are also
serializable, the list was changed to a list of Serializable instead.

The latter change can be reverted, if it causes compilation issues
elsewhere.  However, it seems safer to enforce serializability in the
list rather than risk having a later change inject a non-serializable
object into the list.

Change-Id: Ia741a1a96ec4efcc63451e9af31c19b4fe99dd7d
Issue-ID: POLICY-2225
Signed-off-by: Jim Hahn <jrh3@att.com>
4 years agoUse lombok annotations for objects in models-interaction/models-impl module 89/97989/4
Rashmi Pujar [Tue, 5 Nov 2019 22:10:00 +0000 (17:10 -0500)]
Use lombok annotations for objects in models-interaction/models-impl module

Issue-ID: POLICY-1896
Signed-off-by: Rashmi Pujar <rashmi.pujar@bell.ca>
Change-Id: I425afe25876cea91908391418582ef584e6fe6fc

4 years agoCleanup up unused actor.test maven module 70/97970/1
Rashmi Pujar [Tue, 5 Nov 2019 16:19:58 +0000 (11:19 -0500)]
Cleanup up unused actor.test maven module

Issue-ID: POLICY-1894
Signed-off-by: Rashmi Pujar <rashmi.pujar@bell.ca>
Change-Id: Ib662aa6a28beb40c2a1e6814b103e95ebf4ee2e1

4 years agoMerge "PNF support changes in policy/models"
Liam Fallon [Mon, 4 Nov 2019 17:59:31 +0000 (17:59 +0000)]
Merge "PNF support changes in policy/models"

4 years agoPNF support changes in policy/models 08/97708/8
Rashmi Pujar [Tue, 29 Oct 2019 20:13:05 +0000 (16:13 -0400)]
PNF support changes in policy/models

AAI Enrichment method for PNF target-type and unit tests.
Addition of a hashmap field to ControlLoopEvent class to hold event specific parameters.
Update CDS actor to include additional event parameters

Issue-ID: POLICY-1187
Signed-off-by: Rashmi Pujar <rashmi.pujar@bell.ca>
Change-Id: Ie0ceb320943531de6e6bc8675844b29a358dfb7e

4 years agoAdd SDNC Naming Policy Type and example policy 60/97860/2
Pamela Dragosh [Fri, 1 Nov 2019 15:22:34 +0000 (11:22 -0400)]
Add SDNC Naming Policy Type and example policy

Will be used to create naming application for XACML PDP.

Issue-ID: POLICY-1740
Change-Id: I996537da16bdb386f4bcddd0008055b8ffac417e
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
4 years agoAdd common Jersey version 58/97858/1
liamfallon [Fri, 1 Nov 2019 11:24:26 +0000 (11:24 +0000)]
Add common Jersey version

Add a common version of Jersey for all Policy Framework components.

Issue-ID: POLICY-2209
Change-Id: Ic1d2ea808bb41156f776d18b875e44de22fbf06b
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoMerge "Change field names in policy notifications to match wiki"
Jorge Hernandez [Fri, 1 Nov 2019 13:22:20 +0000 (13:22 +0000)]
Merge "Change field names in policy notifications to match wiki"

4 years agoFix Checkstyle issues in policy-models 40/97840/1
liamfallon [Fri, 1 Nov 2019 06:55:23 +0000 (06:55 +0000)]
Fix Checkstyle issues in policy-models

Some minor checkstyle issues were introduced into policy-models by
recent reviews.

Issue-ID: POLICY-2088
Change-Id: I84af19926432081d72e2054af788cdc35850a99c
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoChange field names in policy notifications to match wiki 32/97832/2
Jim Hahn [Thu, 31 Oct 2019 21:39:47 +0000 (17:39 -0400)]
Change field names in policy notifications to match wiki

Field names looked like "policyType.name".  Changed them to look like
"policy-type", instead, to match the wiki for the notifications to be
sent to DCAE.

Change-Id: Ib3cef1712fd12a44db8acdcff2245d800b21137a
Issue-ID: POLICY-2190
Signed-off-by: Jim Hahn <jrh3@att.com>
4 years agoMerge "Changes in preparation for the m2 model (part 2)"
Jorge Hernandez [Wed, 30 Oct 2019 15:56:26 +0000 (15:56 +0000)]
Merge "Changes in preparation for the m2 model (part 2)"

4 years agoChanges in preparation for the m2 model (part 2) 73/97673/2
Straubs, Ralph (rs8887) [Tue, 29 Oct 2019 12:17:23 +0000 (07:17 -0500)]
Changes in preparation for the m2 model (part 2)

This change was missed earlier: convert 'ResourceType' to a 'String',
so application-specific types can be added.

Issue-ID: POLICY-1948
Change-Id: Ie8a35e7fb0746d8c8e3a6db11c09ca31dc4763cc
Signed-off-by: Straubs, Ralph (rs8887) <rs8887@att.com>
4 years agoMerge "Refactor Appc LCM Model"
Jorge Hernandez [Tue, 29 Oct 2019 13:25:58 +0000 (13:25 +0000)]
Merge "Refactor Appc LCM Model"

4 years agoRefactor Appc LCM Model 09/97509/5
Daniel Cruz [Wed, 23 Oct 2019 22:33:28 +0000 (17:33 -0500)]
Refactor Appc LCM Model

Added model classes for APPC LCM Input and APPC LCM Output
and removed adding the input/output tag to the JSON via
the APPC LCM custom serializer.

Issue-ID: POLICY-2043
Signed-off-by: Daniel Cruz <dc443y@att.com>
Change-Id: I54e1b5f589a4b29357cf1a45dbdf2173610870ce

4 years agoMerge "Changes in preparation for the m2 model"
Jim Hahn [Fri, 25 Oct 2019 14:12:25 +0000 (14:12 +0000)]
Merge "Changes in preparation for the m2 model"

4 years agoChanges in preparation for the m2 model 30/97430/4
Straubs, Ralph (rs8887) [Tue, 22 Oct 2019 15:43:09 +0000 (10:43 -0500)]
Changes in preparation for the m2 model

1) Replace enum 'ControlLoopTargetType' with 'String' -- symbols such as
   'ControlLoopTargetType.VM' still work, but now expand into a String.
   This gives the ability to add new application-specific types.

2) Move 'ControlLoopEvent.payload' to 'VirtualControlLoopEvent'. This
   symbol isn't common to all 'ControlLoopEvent' types, and this
   definition collides with a 'payload' defined in our application.

3) Add 'RestManager.patch(...)', which performs a REST patch.

4) Add lombok getters and setters

5) Remove trailing spaces

6) Fix order of arguments in 'assertEquals' in 'ControlLoopTargetTypeTest'

7) Update Junit tests in 'RestTest' to include 'RestManager.patch(...)'

Issue-ID: POLICY-1948
Signed-off-by: Straubs, Ralph (rs8887) <rs8887@att.com>
Change-Id: I08e04ea3cbcf368c760b630bcfe23a4370cf94dc

4 years agoChanged the serialized name of policy notifications 63/97563/1
Jim Hahn [Thu, 24 Oct 2019 15:50:42 +0000 (11:50 -0400)]
Changed the serialized name of policy notifications

Changed the serialized name of the policy identifier from "policy"
to "policy-id".

Change-Id: I7188b65428728b65fef38c70e9fae99202ab0eea
Issue-ID: POLICY-1841
Signed-off-by: Jim Hahn <jrh3@att.com>
4 years agoMerge "Flatten the CDS grpc request payload"
Liam Fallon [Thu, 24 Oct 2019 13:18:20 +0000 (13:18 +0000)]
Merge "Flatten the CDS grpc request payload"

4 years agoFlatten the CDS grpc request payload 36/97436/4
Rashmi Pujar [Tue, 22 Oct 2019 19:58:38 +0000 (15:58 -0400)]
Flatten the CDS grpc request payload

Before:
{
    "vfw-modify-config-request":{
        "resolution-key":"1234567890",
        "aai-properties":{
            "service-instance.service-instance-id":"1234",
            "generic-vnf.vnf-id":"5678"
        },
        "policy-payload":{
            "data":"{\"active-streams\":\"5\"}"
        }
    }
}

After:
{
    "vfw-modify-config-request":{
        "resolution-key":"1234567890",
        "vfw-modify-config-properties":{
            "service-instance.service-instance-id":"1234",
            "generic-vnf.vnf-id":"5678",
            "data":"{\"active-streams\":\"5\"}"
        }
    }
}

Issue-ID: POLICY-2089
Signed-off-by: Rashmi Pujar <rashmi.pujar@bell.ca>
Change-Id: I139a7ca3e1e2d0cd50bbd86d0cdf499f215be74f

4 years agoUpdate optimization policies to have version 87/97387/1
Pamela Dragosh [Mon, 21 Oct 2019 17:59:02 +0000 (13:59 -0400)]
Update optimization policies to have version

These should be version 1.0.0. Add in a no version test.

Issue-ID: POLICY-2066
Change-Id: Ie113c02c37e95b86dbb31247bf7a9fda09f724b1
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
4 years agoMerge "Add PolicyNotification.isEmpty() method"
Liam Fallon [Fri, 18 Oct 2019 09:47:22 +0000 (09:47 +0000)]
Merge "Add PolicyNotification.isEmpty() method"

4 years agoAdd PolicyNotification.isEmpty() method 79/97279/1
Jim Hahn [Thu, 17 Oct 2019 18:58:59 +0000 (14:58 -0400)]
Add PolicyNotification.isEmpty() method

Change-Id: I5cf5f21b968975018bd1f18daa1653289b837d2e
Issue-ID: POLICY-1841
Signed-off-by: Jim Hahn <jrh3@att.com>
4 years agoRemove the CDS blueprint name and version from its payload. 69/97269/2
Rashmi Pujar [Thu, 17 Oct 2019 15:43:02 +0000 (11:43 -0400)]
Remove the CDS blueprint name and version from its payload.

This information is redundant since it is included in the request header.
Found during integration testing

Issue-ID: POLICY-2089
Signed-off-by: Rashmi Pujar <rashmi.pujar@bell.ca>
Change-Id: Icdb4753ccae687f85318f5efeed09d5e13a6853b

4 years agoMerge "Remove actor and recipe checks from ControlLoopCompiler.java"
Jorge Hernandez [Tue, 15 Oct 2019 16:19:40 +0000 (16:19 +0000)]
Merge "Remove actor and recipe checks from ControlLoopCompiler.java"

4 years agoRemove actor and recipe checks from ControlLoopCompiler.java 64/96764/3
dg5762 [Tue, 8 Oct 2019 21:04:55 +0000 (16:04 -0500)]
Remove actor and recipe checks from ControlLoopCompiler.java

Remove actor and recipe checks from ControlLoopCompiler.java
and adjusted associated JUNIT tests for the changes that were
implented. Removed some redundant variables, replaced null check
in actor/recipe with blank string, which checks for null as
well as empty/blank strings. drools-applications still builds
correctly.

Issue-ID: POLICY-2128
Change-Id: I83d9e3b1152d87c9c8d2c90586300aebdd53b8e2
Signed-off-by: dg5762 <dg5762@att.com>
4 years agoAdd PAP Policy Notification classes 65/97065/7
Jim Hahn [Mon, 14 Oct 2019 15:34:15 +0000 (11:34 -0400)]
Add PAP Policy Notification classes

Added classes that PAP will use to publish to DMaaP to indicate policy
status changes (i.e., added/removed from PDPs).
Modified serialized name of the policy identified to match other uses
(e.g., PAP REST API calls).
Added policy type, per review comments.

Change-Id: I66131fa9ae0b63081f239e7f402b7fea65c434a5
Issue-ID: POLICY-1841
Signed-off-by: Jim Hahn <jrh3@att.com>
4 years agoFix remaining fixable Sonar issues on policy models 16/97116/1
liamfallon [Tue, 15 Oct 2019 11:26:48 +0000 (12:26 +0100)]
Fix remaining fixable Sonar issues on policy models

This patch fixes the remaining  easy to fix Sonar issues on policy
models. The remaining issues are
- methods that do not follow Java naming conventions and fixing those
  will probably break policies that use those methods
- TODO statements to do with functionality we didn't get done in Dublin
  and will address in Frankfurt

Issue-ID: POLICY-2165
Change-Id: I7f604bc2335388bdc0dd9286ae17a5ab76517665
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoClean up minor things in policy-models 60/97060/3
liamfallon [Mon, 14 Oct 2019 13:25:58 +0000 (14:25 +0100)]
Clean up minor things in policy-models

Cleam up of some minor eclipse, checkstyle, and Sonar issues in
policy-models

Issue-ID: POLICY-2165
Change-Id: Id5682fd60e1a6cebbf716d9c258453aa53ca2482
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoMerge "Clean up SONAR issues in CDS actor"
Liam Fallon [Mon, 14 Oct 2019 13:19:26 +0000 (13:19 +0000)]
Merge "Clean up SONAR issues in CDS actor"

4 years agoFix dmaap simulator junit 56/96956/1
Jim Hahn [Fri, 11 Oct 2019 16:02:58 +0000 (12:02 -0400)]
Fix dmaap simulator junit

Modified the code to leave the topics open through-out the test cases,
and simply clear the queues between each test case.  Hopefully that
will fix the EndToEndTest junit in the dmaap simulator.

Change-Id: I3658df4dbc70cd47fec1cfb84c7a2365133105ff
Issue-ID: POLICY-2144
Signed-off-by: Jim Hahn <jrh3@att.com>
4 years agoClean up SONAR issues in CDS actor 43/96943/2
liamfallon [Fri, 11 Oct 2019 13:56:46 +0000 (14:56 +0100)]
Clean up SONAR issues in CDS actor

Issue-ID: POLICY-2165
Change-Id: I2ccfb32193c85958d525af19a7744a74c97a3485
Signed-off-by: liamfallon <liam.fallon@est.tech>
4 years agoMerge "Added new policy example to support junit test for new simplified API"
Jorge Hernandez [Thu, 10 Oct 2019 21:37:37 +0000 (21:37 +0000)]
Merge "Added new policy example to support junit test for new simplified API"

4 years agoAdded new policy example to support junit test for new simplified API 32/96832/1
Chenfei Gao [Wed, 9 Oct 2019 20:39:35 +0000 (16:39 -0400)]
Added new policy example to support junit test for new simplified API

Issue-ID: POLICY-1991
Change-Id: Ib52bffe7895dc0625c77da7aa954bb71ed16187d
Signed-off-by: Chenfei Gao <cgao@research.att.com>
4 years agoAdded ModelType to SO Req. 19/96819/1
pramod.jamkhedkar [Wed, 9 Oct 2019 17:42:25 +0000 (13:42 -0400)]
Added ModelType to SO Req.

Added ModelType to SO Request and set it to vfModule

Issue-ID: POLICY-2156
Change-Id: Icfd824ff1f521ec32a711506d01283566d2a7ed9
Signed-off-by: pramod.jamkhedkar <pramod@research.att.com>
4 years agoCorrect the CDS basic auth header in the request 49/96749/1
Rashmi Pujar [Tue, 8 Oct 2019 18:46:09 +0000 (14:46 -0400)]
Correct the CDS basic auth header in  the request

Issue-ID: POLICY-2088
Signed-off-by: Rashmi Pujar <rashmi.pujar@bell.ca>
Change-Id: Ibcdfdbd1de66fcf193e52fcc14a1220c7520f140