policy/drools-applications.git
6 years agoAdd guard simulator and multiple AAI responses 71/14371/2
Charles Cole [Thu, 21 Sep 2017 19:20:42 +0000 (14:20 -0500)]
Add guard simulator and multiple AAI responses

Added a guard simulator that can permit or deny (it sends a deny if the
clname is denyGuard).  Added responses to the AAI simulator to set the
is-closed-loop-disabled to true (use a get query with a key of
disableClosedLoop). Changed the content-type of all responses to
application/json.

Issue-ID: POLICY-256
Change-Id: If84813968d3ea59d9ebe029caa69f444a1f413c8
Signed-off-by: Charles Cole <cc847m@att.com>
6 years agoMerge "ONAP AAI GET QUERY code to support ONAP project"
Jorge Hernandez [Thu, 21 Sep 2017 19:38:11 +0000 (19:38 +0000)]
Merge "ONAP AAI GET QUERY code to support ONAP project"

6 years agoONAP AAI GET QUERY code to support ONAP project 55/13155/17
Joseph Chou [Tue, 19 Sep 2017 20:39:56 +0000 (16:39 -0400)]
ONAP AAI GET QUERY code to support ONAP project

check in code to use simulator url

Issue-ID: POLICY-103
Change-Id: I352140dd3cb3159fc2c5738bf02dbb6272de48bc
Signed-off-by: Joseph Chou <jc2555@att.com>
6 years agoMerge "Implement restful call to xacml pdp guard"
Jorge Hernandez [Thu, 21 Sep 2017 17:49:29 +0000 (17:49 +0000)]
Merge "Implement restful call to xacml pdp guard"

6 years agoMerge "Upgrade to oparent release version"
Jorge Hernandez [Thu, 21 Sep 2017 17:30:13 +0000 (17:30 +0000)]
Merge "Upgrade to oparent release version"

6 years agopdp-d feature to simulate aai/mso/vfc in lab 53/14053/2
Jorge Hernandez [Thu, 21 Sep 2017 04:12:27 +0000 (23:12 -0500)]
pdp-d feature to simulate aai/mso/vfc in lab

implemented as an optional loadable feature, this
capability enables to bring up simulators used by
junits in a pdp-d lab configuration.

After lab installation, perform:

1. features enable controlloop-util
2. policy start

Now the simulators are opened at ports 6666, 6667, and 6668.

netstat output:
tcp6       0      0 127.0.0.1:6666          :::*                    LISTEN      21562/java
tcp6       0      0 127.0.0.1:6667          :::*                    LISTEN      21562/java
tcp6       0      0 127.0.0.1:6668          :::*                    LISTEN      21562/java

21562 is the pdp-d PID in the lab.

curl http://localhost:6666/aai/v11/network/generic-vnfs/generic-vnf/vnfIdA
{ "vnf-id": "5e49ca06-2972-4532-9ed4-6d071588d792", ... }

Change-Id: I3f05333ce5549b2274eb967b2b8866189b7f8843
Issue-ID: POLICY-259
Signed-off-by: Jorge Hernandez <jh1730@att.com>
6 years agoUpgrade to oparent release version 05/14305/1
Pamela Dragosh [Thu, 21 Sep 2017 15:23:35 +0000 (11:23 -0400)]
Upgrade to oparent release version

Following independent release and versioning process guidelines.

Issue-ID: POLICY-225
Change-Id: If679e4002690bb7614c72fb846c383eb265fb2e0
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years agoImplement restful call to xacml pdp guard 57/13557/10
Temoc Rodriguez [Tue, 19 Sep 2017 18:13:34 +0000 (11:13 -0700)]
Implement restful call to xacml pdp guard

Removed the embedded guard decision and replace with restful call to
xacml pdp to restore guard functionality. Set guard URL with PolicyEngine env properties. Modified templates accordingly.

Issue-Id: POLICY-260
Change-Id: Ic1558a6ebdd5f6d1b74a748f69433f6213dbf984
Signed-off-by: Temoc Rodriguez <cr056n@att.com>
Signed-off-by: Hockla, Ali (ah999m) <ah999m@att.com>
6 years agoMerge "Fix for Sonar major issues"
Jorge Hernandez [Wed, 20 Sep 2017 21:06:10 +0000 (21:06 +0000)]
Merge "Fix for Sonar major issues"

6 years agoMerge "Fixing VFC simulator for junit tests"
Pamela Dragosh [Wed, 20 Sep 2017 11:20:28 +0000 (11:20 +0000)]
Merge "Fixing VFC simulator for junit tests"

6 years agoMerge "Fix Major sonar issues"
Pamela Dragosh [Wed, 20 Sep 2017 10:54:52 +0000 (10:54 +0000)]
Merge "Fix Major sonar issues"

6 years agoFix for Sonar major issues 37/13737/2
SwapnilPathak [Wed, 20 Sep 2017 07:34:50 +0000 (13:04 +0530)]
Fix for Sonar major issues

Add override annotation above the method signature.

Issue-ID: POLICY-248
Change-Id: I8086a6fc1dc24719c3ffd3785a12c086ab453ae9
Signed-off-by: SwapnilPathak <SP00494485@techmahindra.com>
6 years agoFix Major sonar issues 57/13357/2
shashikanth [Tue, 19 Sep 2017 08:39:45 +0000 (14:09 +0530)]
Fix Major sonar issues

Fix Major sonar issues in policy/drools-applications module
https://sonar.onap.org/component_issues?id=org.onap.policy.drools-applications%3Adrools-pdp-apps#resolved=false|severities=MAJOR

Add the "@Override" annotation above this method signature
"value" is already a string, there's no need to call "toString()" on it

Issue-Id:POLICY-239
Change-Id: Ia64ac87c13d88c5d961b943e0b2286b273bd4831
Signed-off-by: shashikanth.vh <shashikanth.vh@huawei.com>
6 years agotest tooling to generate vcpe use case in lab 21/13621/1
Jorge Hernandez [Wed, 20 Sep 2017 00:55:42 +0000 (19:55 -0500)]
test tooling to generate vcpe use case in lab

run successully vcpe case in lab in 2 steps:

1.  docker-install load
2.  run create-cl-amsterdam (with defaults)
3.  injecting dcae.onset and appc.success packaged
    with archetypes

Change-Id: Idb20c0078228da962510dbf36dae96aceb43546c
Issue-ID: POLICY-162
Signed-off-by: Jorge Hernandez <jh1730@att.com>
6 years agoMerge "Adding reading service-id from AA&I"
Jorge Hernandez [Tue, 19 Sep 2017 19:11:51 +0000 (19:11 +0000)]
Merge "Adding reading service-id from AA&I"

6 years agoenhancements to archetype and apps packaging 93/13493/1
Jorge Hernandez [Tue, 19 Sep 2017 14:09:05 +0000 (09:09 -0500)]
enhancements to archetype and apps packaging

Change-Id: I3e659d35d3cb397c011657f39ef12b10b0564fc9
Issue-ID: POLICY-162
Signed-off-by: Jorge Hernandez <jh1730@att.com>
6 years agoRemove sonar blocker and unused import 65/13465/1
Pamela Dragosh [Tue, 19 Sep 2017 13:03:19 +0000 (09:03 -0400)]
Remove sonar blocker and unused import

Remove the 3 sonar blockers and unused import in AAI code.

Issue-ID: POLICY-111
Change-Id: I73001a06810ecff3f22da627583a0238c4a09967
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years agoInherit guard install env properties for cl. 79/13179/1
Jorge Hernandez [Mon, 18 Sep 2017 16:26:58 +0000 (11:26 -0500)]
Inherit guard install env properties for cl.

Clean up a few "mso" references.
Disable 1.0.0 template build for now (note that some
references are still pointing to old mso).
Ie., see
https://git.onap.org/policy/drools-applications/tree/controlloop
       /templates/template.demo.v1.0.0/template.demo
       /src/test/java/org/onap/policy/template/demo/TestSO.java

Since this
is going away, rather than maintaining it, and changing this
code, disabling it for the build.
It will be deleted within the next few days.

Issue-ID: POLICY-162
Change-Id: Ibb819a318fbbb2b7f3aa14cdf76155bdec321024
Signed-off-by: Jorge Hernandez <jh1730@att.com>
6 years agoMerge "Fix sonar critical"
Jorge Hernandez [Mon, 18 Sep 2017 13:52:01 +0000 (13:52 +0000)]
Merge "Fix sonar critical"

6 years agoFixing VFC simulator for junit tests 99/13199/1
Ritu Sood [Mon, 18 Sep 2017 10:01:54 +0000 (03:01 -0700)]
Fixing VFC simulator for junit tests

Added response type to post and removed
response id as it is unused.
Breaking up from the junit patch for ease of
review.

Issue-id: POLICY-212
Change-Id: I0c6b0c02b240cfe81246587184fe6a589dcc2367
Signed-off-by: Ritu Sood <ritu.sood@intel.com>
6 years agoAdding reading service-id from AA&I 07/13007/2
Ritu Sood [Sun, 17 Sep 2017 22:34:16 +0000 (15:34 -0700)]
Adding reading service-id from AA&I

For VFC adding getting service-id from AA&I.

Issue-Id: POLICY-57
Change-Id: I740c7749bfb2d395851cbd5eb3e486bf4eb9b560
Signed-off-by: Ritu Sood <ritu.sood@intel.com>
6 years agoFix sonar critical 07/12807/1
Pamela Dragosh [Fri, 15 Sep 2017 21:05:44 +0000 (17:05 -0400)]
Fix sonar critical

Last transient/serializable issues.
Throw a dedicated exception for DateUtil class
Unused imports
Make the enclosing method "static" or remove this set.

Issue-ID: POLICY-115
Change-Id: I366f85922c4d4d290b320e0b88678c805de59872
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years agoMerge "ONAP AAI GET Query code"
Jorge Hernandez [Fri, 15 Sep 2017 19:47:25 +0000 (19:47 +0000)]
Merge "ONAP AAI GET Query code"

6 years agoMerge "Fix sonar criticals"
Jorge Hernandez [Fri, 15 Sep 2017 18:58:52 +0000 (18:58 +0000)]
Merge "Fix sonar criticals"

6 years agoONAP AAI GET Query code 91/12291/2
Joseph Chou [Wed, 13 Sep 2017 21:15:49 +0000 (17:15 -0400)]
ONAP AAI GET Query code

Update ControlLoopEventManager to raise exception on null AAI response

Issue-ID: POLICY-103
Change-Id: Iebe8b03269a1801c4293600920aa267490cea1af
Signed-off-by: Joseph Chou <jc2555@att.com>
6 years agoFix sonar criticals 65/12765/1
Pamela Dragosh [Fri, 15 Sep 2017 15:41:47 +0000 (11:41 -0400)]
Fix sonar criticals

Either re-interrupt this method or rethrow Exception
Transient/Serializable issues
Unused imports
logging exceptions

Issue-ID: POLICY-115
Change-Id: I4c8a0c780e2f6c6e8218c1457f18470f7d95919c
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years agoMaster lab template changes for MSO rename to SO 59/12759/1
Hockla, Ali (ah999m) [Fri, 15 Sep 2017 17:17:37 +0000 (12:17 -0500)]
Master lab template changes for MSO rename to SO

Issue-ID: POLICY-162

Change-Id: Ieb0952379cd854e0ed8e4a3b068b7e29f3b93770
Signed-off-by: Hockla, Ali (ah999m) <ah999m@att.com>
6 years agoMerge "Modify AAI simulator to support new requests"
Pamela Dragosh [Fri, 15 Sep 2017 16:42:40 +0000 (16:42 +0000)]
Merge "Modify AAI simulator to support new requests"

6 years agoModify AAI simulator to support new requests 93/12293/2
Charles Cole [Wed, 13 Sep 2017 16:00:21 +0000 (11:00 -0500)]
Modify AAI simulator to support new requests

Updated the AAI simulator to support new AAI queries.  Also, modified
the post response to allow multiple responses.  Added code to ensure the
simulators were able to sucessfully start up.

Change-Id: I3e855b5e54c073f55fbaadc0064c140695fc1a58
Issue-ID: POLICY-200
Signed-off-by: Charles Cole <cc847m@att.com>
6 years agoClear eclipse warnings and sonar 67/12567/1
Pamela Dragosh [Thu, 14 Sep 2017 22:00:36 +0000 (18:00 -0400)]
Clear eclipse warnings and sonar

Removing warnings introduced with A&AI code. This should also
address sonar criticals and majors.

Issue-ID: POLICY-140
Change-Id: I3f8186dd9c5aa52bfbb061bf95d67b5614b3fb2e
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years agoMerge "Move credential information out of persistence.xml"
Jorge Hernandez [Thu, 14 Sep 2017 21:35:26 +0000 (21:35 +0000)]
Merge "Move credential information out of persistence.xml"

6 years agoMerge "master lab template maintained under archetype"
Jorge Hernandez [Thu, 14 Sep 2017 21:30:58 +0000 (21:30 +0000)]
Merge "master lab template maintained under archetype"

6 years agomaster lab template maintained under archetype 79/12379/6
Jorge Hernandez [Thu, 14 Sep 2017 06:55:30 +0000 (01:55 -0500)]
master lab template maintained under archetype

This is work in progress, the official pom.xml with dependencies,
drl template, and support files for controller deployment
are maintained here.   In the near future the junit template
should be consolidated with this one.

Added controlloop.properties.environment, this environment file
will be populated at installation time with the lab's aai url,
etc .. and will be accessible by any drools application such as
control loops through the PolicyEngine interface.   Note that PDP-D
server already supports these environment files, so it is just natural.
Therefore, this is the default mechanism to provide to applications, the url, username,
and passwords to use at runtime by the control loops for the time being.
In the future MSB could set them globally here through existing APIs,
or it can be queried by any drools application using MSB library,
doesn't matter.

There's been some trouble playing nicely with the dependencies used
by a control loop application classsloader, and the pdp-d middleware one,
causing issues between dependencies version of libraries.  Specifically,
the snakeyaml library does not play well across classloader when using
constructor functionality, note that the snakeyaml libraries are pulled
also from jackson parsers used in the pdp-d.   I made a change in ControlLoopProcessor
to specifically tell the "Yaml" object which classloader to use in order to
find the class with the constructor that is intended to be built, otherwise,
yaml libraries use a different classloader that does not have visibility
into the ControlLoopPolicy that is trying to construct, and fails.   This also
should respect junits that use the same classloader I pressume and does not
give issues.

Change-Id: I36271d29cdbf8ff861f9c03ff91cf7116927906a
Issue-ID: POLICY-162
Signed-off-by: Jorge Hernandez <jh1730@att.com>
6 years agoMove credential information out of persistence.xml 71/12271/4
Temoc Rodriguez [Wed, 13 Sep 2017 19:23:46 +0000 (12:23 -0700)]
Move credential information out of persistence.xml

Move credential information out of persistence.xml. Define properties
file which will contain the credentials instead. Access db using new
properties file.

Issue-ID: POLICY-55
Change-Id: I01ad0611c053ad4285de2a225fca7920a3b1bc8f
Signed-off-by: Temoc Rodriguez <cr056n@att.com>
6 years agoMerge "Added changes for vDNS Use Case"
Jorge Hernandez [Thu, 14 Sep 2017 18:26:20 +0000 (18:26 +0000)]
Merge "Added changes for vDNS Use Case"

6 years agoAdded changes for vDNS Use Case 65/12265/2
Hockla, Ali (ah999m) [Wed, 13 Sep 2017 14:24:43 +0000 (09:24 -0500)]
Added changes for vDNS Use Case

-Renamed remaining MSO classes and packages to SO and modified drl
accordingly
-Connected SO Interface to SO Simulator
-Added vDNS Control Loop junit
-Modified SOActorServiceProvider to reflect AAI class changes (POLICY-103)

Issue-ID: POLICY-102

Change-Id: Iea5d3f096c4ccfedde68e79d7593d66331127aaf
Signed-off-by: Hockla, Ali (ah999m) <ah999m@att.com>
6 years agoFix AAINQF199 object references to AAINQ objects 43/12243/1
daniel [Wed, 13 Sep 2017 16:49:12 +0000 (11:49 -0500)]
Fix AAINQF199 object references to AAINQ objects

This is a small change to now reference the new AAI model
instead of using the older AAINQF199 model.

Issue-ID: POLICY-104
Change-Id: I2a1d2830fbd3bd7d62a9e27067a8c32a1c1ab4b1
Signed-off-by: daniel <dc443y@att.com>
6 years agoMerge "Fix A&AI Named Query for vFW"
Jorge Hernandez [Wed, 13 Sep 2017 13:59:58 +0000 (13:59 +0000)]
Merge "Fix A&AI Named Query for vFW"

6 years agoMerge "ONAP code for AAI, consolidate name and get query"
Jorge Hernandez [Wed, 13 Sep 2017 13:58:47 +0000 (13:58 +0000)]
Merge "ONAP code for AAI, consolidate name and get query"

6 years agoFix A&AI Named Query for vFW 87/11987/2
daniel [Tue, 12 Sep 2017 14:44:59 +0000 (09:44 -0500)]
Fix A&AI Named Query for vFW

The vFW named query has now been verified with the
A&AI simulator. Null checks were added to make the
namedQuery method work properly. In addition, a
recursive A&AI response parser was added to traverse
the response to find the correct generic-vnf object
with the target vnf-id.

For now the simulator URL is hard coded and the UUID
of the named query is hard coded. These should be
configurable in future releases.

Issue-ID: POLICY-104
Change-Id: I05a1a992ff68ca2c17fb6a578983e6b21626bf44
Signed-off-by: Daniel Cruz <dc443y@att.com>
6 years agoONAP code for AAI, consolidate name and get query 39/10639/7
Joseph Chou [Wed, 6 Sep 2017 20:54:33 +0000 (16:54 -0400)]
ONAP code for AAI, consolidate name and get query

Adding AAI GET query feature to support ONAP project (1 commit)

Issue-ID: POLICY-103
Change-Id: I0a55f41c3edd7a0bc0562ae4e12a19f262a50d74
Signed-off-by: Joseph Chou <jc2555@att.com>
6 years agoMerge "Fix nullPointerException"
Jorge Hernandez [Tue, 12 Sep 2017 20:18:45 +0000 (20:18 +0000)]
Merge "Fix nullPointerException"

6 years agoMerge "Fixing VFC Model response class"
Pamela Dragosh [Tue, 12 Sep 2017 19:29:46 +0000 (19:29 +0000)]
Merge "Fixing VFC Model response class"

6 years agoFix nullPointerException 77/11977/2
Temoc Rodriguez [Tue, 12 Sep 2017 15:23:53 +0000 (08:23 -0700)]
Fix nullPointerException

Fix nullPointerException by changing return values of attributesProvided
and attributesRequired from null to empty Set.

Issue-ID: POLICY-55
Change-Id: I9516a9bcad591cc582834cb49fa54e58a1f45a47
Signed-off-by: Temoc Rodriguez <cr056n@att.com>
6 years agoFixing VFC Model response class 45/11745/4
Ritu Sood [Mon, 11 Sep 2017 11:22:17 +0000 (04:22 -0700)]
Fixing VFC Model response class

Fixed the response class for VFC response
and also removed the Ignore test case.

Change-Id: I4373e86399089b7a3d743be4d19f76cc37d1ceea
Issue-id: POLICY-57
Signed-off-by: Ritu Sood <ritu.sood@intel.com>
6 years agoAdd Support for Locking VNF Target Types 57/11757/1
daniel [Mon, 11 Sep 2017 19:42:59 +0000 (14:42 -0500)]
Add Support for Locking VNF Target Types

Fixed the target lock to support vnf target_types.
Generic-vnf.vnf-id and generic-vnf.vnf-name are also
supported when retrieving the target instance from the onset.
These changes are relfected in the vFW and vCPE junits as
they now work with VNF target types.

Issue-ID: POLICY-222
Change-Id: I92abeb02c769d35f3a9912cce6eaaec4c9cc8efb
Signed-off-by: Daniel Cruz <dc443y@att.com>
6 years agoMove the simulators to a new package 19/11719/2
Charles Cole [Fri, 8 Sep 2017 19:10:57 +0000 (14:10 -0500)]
Move the simulators to a new package

Moved the simulators to the simulators project in controlloop/common.
They can now be accessed with the Util class in the simulators project
or the Util class in template.demo, for backwards compatability. Also
renamed AaiSimulator to AaiSimulatorJaxRs

Issue-IS: POLICY-200
Change-Id: Id131af0243777db31a8f22e110d8a708dc033dcf
Signed-off-by: Charles Cole <cc847m@att.com>
6 years agoFix Eclipse warnings for raw type parameterization 01/11701/1
Pamela Dragosh [Mon, 11 Sep 2017 15:30:38 +0000 (11:30 -0400)]
Fix Eclipse warnings for raw type parameterization

Eclipse generates warnings for raw types and 2 fields are not accessed statically.

Issue-ID: POLICY-102
Change-Id: Ibeb2a76d527949cfd7283ab1a78d97e582725337
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years agoMerge "Cleanup project's name in Sonar"
Pamela Dragosh [Mon, 11 Sep 2017 12:12:15 +0000 (12:12 +0000)]
Merge "Cleanup project's name in Sonar"

6 years agoSet this class as serializable 29/11429/1
Pamela Dragosh [Fri, 8 Sep 2017 22:03:33 +0000 (18:03 -0400)]
Set this class as serializable

Fixing sonar critical to make this simple class serializable.

Issue-ID: POLICY-115
Change-Id: I6a3cf8b1c8c27f434e26d9f2909b2ef38c72825b
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years agoCleanup project's name in Sonar 21/11321/1
Jessica Wagantall [Fri, 8 Sep 2017 20:33:33 +0000 (13:33 -0700)]
Cleanup project's name in Sonar

The name parameter in the root pom.xml should
match the project name in gerrit to reflect consistency
in Sonar.

Change-Id: If7e35a530da07411dc0b534da7f185bdb43368dd
Issue-id: CIMAN-65
Signed-off-by: Jessica Wagantall <jwagantall@linuxfoundation.org>
6 years agoMerge "Clearing sonar critical for missing serialization"
Pamela Dragosh [Fri, 8 Sep 2017 16:47:59 +0000 (16:47 +0000)]
Merge "Clearing sonar critical for missing serialization"

6 years agoClearing sonar critical for missing serialization 49/11149/2
Pamela Dragosh [Fri, 8 Sep 2017 15:52:11 +0000 (11:52 -0400)]
Clearing sonar critical for missing serialization

These classes should be serializable in order to remove the sonar critical.
Also clearing unused import/code messages.

Issue-ID: POLICY-115
Change-Id: I25e504f6edae9fb38080e7d4d33b2b3e4cde4637
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years agoAdded changes for vDNS Use Case - MSO Interface 11/10411/12
Hockla, Ali (ah999m) [Tue, 5 Sep 2017 19:01:04 +0000 (14:01 -0500)]
Added changes for vDNS Use Case - MSO Interface

Rebased and fixed merge conflicts

Issue-ID: POLICY-102

Change-Id: Icc36a2cf6391aa9137593bc04f0d4543798b7ccd
Signed-off-by: Ali Hockla <ah999m@att.com>
Signed-off-by: Hockla, Ali (ah999m) <ah999m@att.com>
Signed-off-by: HOCKLA <ah999m@att.com>
Signed-off-by: Hockla, Ali (ah999m) <ah999m@att.com>
6 years agoMerge "Support drl compilation at design/development time"
Jorge Hernandez [Thu, 7 Sep 2017 18:41:27 +0000 (18:41 +0000)]
Merge "Support drl compilation at design/development time"

6 years agoAdd in-mem db to ControlLoopXacmlGuardTest 29/9929/5
Temoc Rodriguez [Fri, 1 Sep 2017 15:52:02 +0000 (08:52 -0700)]
Add in-mem db to ControlLoopXacmlGuardTest

Add in-mem specification in test/resources/META-INF/persistence.xml for junit. Use system properties to choose
which db to use. Removed named parameters in PIPEngineHistory.java. Change
6.3.0 versions of drools-core to 6.5.0 in pom. Make PIPEngineGetHistory
query more general. Increased sleep times in junit.

Issue-ID: POLICY-55
Change-Id: I6bc65fd88c43c4e7143f27a7e6d8666c2c4df060
Signed-off-by: Temoc Rodriguez <cr056n@att.com>
6 years agoSupport drl compilation at design/development time 07/10707/2
Jorge Hernandez [Thu, 7 Sep 2017 05:25:19 +0000 (00:25 -0500)]
Support drl compilation at design/development time

Change-Id: I0fe6277f92c0db7f596ff73d81987e2e78b5793e
Issue-ID: POLICY-162
Signed-off-by: Jorge Hernandez <jh1730@att.com>
6 years agoMerge "Add APPC LCM Interface"
Pamela Dragosh [Thu, 7 Sep 2017 10:16:09 +0000 (10:16 +0000)]
Merge "Add APPC LCM Interface"

6 years agoAdd APPC LCM Interface 83/10583/3
daniel [Fri, 11 Aug 2017 16:36:09 +0000 (11:36 -0500)]
Add APPC LCM Interface

The LCM model code and service provider code is implemented.
This model code is now used for the vCPE use case scenario.

The vFW use case is still using the legacy APPC API as
request by APPC for Policy to use in R1. The APPC
service provider now generates a demo legacy APPC
request with pg-streams.

An A&AI named query is implemented for the vFW use case.
The code for obtaining the generic-vnf.vnf-id is not
in use until we set up the A&AI simulator to work
without having cyclical depenncies inside the POMs.

JUnits for the vFW and vCPE use cases are now supported.
These JUnits test the complete flow of each scenario.

A&AI testing is not supported in the JUnit test yet.
These JUnits use a target type of VM as VNF is not
supported yet. This will be changed when the Target
Lock supports VNF.

Amended to fix Sonar blockers.

Issue-ID: POLICY-104
Change-Id: I46869c5fd5094919da55ad563d608fe6d4b6fea7
Signed-off-by: Daniel Cruz <dc443y@att.com>
6 years agoAdd missing license. 89/10589/1
Pamela Dragosh [Wed, 6 Sep 2017 15:12:51 +0000 (11:12 -0400)]
Add missing license.

The license checkstyle is now issueing errors for missing licenses.

Change-Id: I3784c43e8d33d14c0ddd92668c68d400979b862f
Issue-ID: POLICY-206
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years agoAdd vFC and MSO Simulators 21/10021/1
Charles Cole [Fri, 1 Sep 2017 22:33:32 +0000 (17:33 -0500)]
Add vFC and MSO Simulators

Added vFC and MSO Simulators for jUnit testing

Issue-ID: POLICY-201, POLICY-202
Change-Id: Ia30ff6ec74a8ee4fa71ce0456eb6dcb60c897695
Signed-off-by: Charles Cole <cc847m@att.com>
6 years agoAdd mock AAI endpoint for jUnit testing 27/9727/2
Charles Cole [Thu, 31 Aug 2017 14:55:52 +0000 (09:55 -0500)]
Add mock AAI endpoint for jUnit testing

Created an AAI endpoint for use in jUnit testing of closed loops.
Added unit tests for my endpoint.
Added methods to Util in template.demo to support creation of AAI
endpoints and kieSessions.

Issue-ID: POLICY-101
Change-Id: I8e110b79f4c2ca700b29dcb29e9828303772d56d
Signed-off-by: Charles Cole <cc847m@att.com>
6 years agoMerge "Fix Sonar Blockers for Drools-Applications"
Pamela Dragosh [Thu, 31 Aug 2017 16:24:13 +0000 (16:24 +0000)]
Merge "Fix Sonar Blockers for Drools-Applications"

6 years agoFix Sonar Blockers for Drools-Applications 97/9597/1
Mike Babinski [Thu, 31 Aug 2017 05:15:13 +0000 (05:15 +0000)]
Fix Sonar Blockers for Drools-Applications

Issue-ID: POLICY-111

Add null check for pipResponse right before null check of pipResponse.gitAttributes().
Change-Id: Iba52791da1aae6900ab4dd4bb6286c3ac00e00a4
Signed-off-by: Mike Babinski <mb1915@att.com>
6 years agoCL dependencies fixes for lab environment runtime 91/9591/2
Jorge Hernandez [Thu, 31 Aug 2017 04:42:35 +0000 (23:42 -0500)]
CL dependencies fixes for lab environment runtime

This also includes workarounds to the recent oparent dependency
introduction that breaks runtime (with the version-check-maven-plugin).

manifested by loading control loops and failing to load some classes
due to different versions.

The issue was that underlying drools libraries use 3.2.5 and oparent
has included a had dependency with transitive dependencies for some maven
libraries in 3.2.3 and lower version xml parsers.   Bottomoline, the
classpath at runtime was formed by the union of both, with some
libraries being resolved to the oparent one, and others to the drools
one.   These errors are very obscured to debug.

Additional clean up of dependencies versions and order of build
was introduced to avoid issues loading dependencies at runtime in a
lab environment (non-junit)..

Issue-ID: POLICY-162
Change-Id: I019c82e6bed4eab4884cdbf8f6f32472c3a7352f
Signed-off-by: Jorge Hernandez <jh1730@att.com>
6 years agolegacy archetype simplification 85/9385/1
Jorge Hernandez [Wed, 30 Aug 2017 11:25:18 +0000 (06:25 -0500)]
legacy archetype simplification

removes pom warnings on versionn duplication from parent pom.

Change-Id: I7b218d6d72bf4db2692370ecc637dbd74e96290f
Issue-ID: POLICY-162
Signed-off-by: Jorge Hernandez <jh1730@att.com>
6 years agoFix New Sonar Blocker for Drools-Applications 85/9185/1
Mike Babinski [Tue, 29 Aug 2017 18:05:39 +0000 (18:05 +0000)]
Fix New Sonar Blocker for Drools-Applications

Add null checks to stop possible null pointer exceptions.

Issue-ID: POLICY-111
Change-Id: Idafb078edf984712e5d5a4d54763f2723e17c09f
Signed-off-by: Mike Babinski <mb1915@att.com>
6 years agoRestored global ControlLoopLogger 19/9119/1
Magnusen, Drew (dm741q) [Tue, 29 Aug 2017 13:56:58 +0000 (08:56 -0500)]
Restored global ControlLoopLogger

Restored previously deleted global ControlLoopLogger which
is loaded into the kieSession for the test.

Issued-ID: POLICY-197
Change-Id: I55e9a3a0c2627ecbecbef8059e70d672e6157fdc
Signed-off-by: Magnusen, Drew (dm741q) <dm741q@att.com>
6 years agoMerge "Removal of sys.out/err with logger messages"
Jorge Hernandez [Mon, 28 Aug 2017 22:16:36 +0000 (22:16 +0000)]
Merge "Removal of sys.out/err with logger messages"

6 years agoRemoval of sys.out/err with logger messages 55/8655/5
Magnusen, Drew (dm741q) [Thu, 24 Aug 2017 16:37:46 +0000 (11:37 -0500)]
Removal of sys.out/err with logger messages

Removed any use of System.out.println or System.err.println
and replaced with relevant logger statements.

Issue-ID: POLICY-176
Change-Id: I91513267635bfb2a34f2a9650c48f367d53fc842
Signed-off-by: Magnusen, Drew (dm741q) <dm741q@att.com>
6 years agoFix JUnit Test for ControlLoops 35/8935/2
daniel [Mon, 28 Aug 2017 14:13:31 +0000 (09:13 -0500)]
Fix JUnit Test for ControlLoops

Fixed the test case by using getters and setters for Policy objects
in the drl. Added gson dependency in the pom to fix gson runtime errors.

Fixed dependencies in template.demo pom to add vfc.

The drl was having compilation errors in the guard permitted
rule due to the operation request object not being casted
into a VFCRequest when being passed into the VFCManager.

Issue-ID: POLICY-194
Change-Id: Id71c74ad9727ad942a683f63a0dfad3f22b6376b
Signed-off-by: Daniel Cruz <dc443y@att.com>
6 years agoFix Sonar Blocker for Drools-Applications 37/8837/2
Mike Babinski [Fri, 25 Aug 2017 20:56:10 +0000 (20:56 +0000)]
Fix Sonar Blocker for Drools-Applications

Add only the null check for pipResponse.

Issue-ID: POLICY-111
Change-Id: I2721c759f27264ce164110a19ea8c649b74869df
Signed-off-by: Mike Babinski <mb1915@att.com>
6 years agoAdd VFC integration code 17/8517/3
Ritu Sood [Wed, 23 Aug 2017 14:52:20 +0000 (07:52 -0700)]
Add VFC integration code

This patch adds VFC Actor code and updates drool template for VFC.
This is WIP patch. There are two opens for this patch that are
still in discussion

1) AA&I fields in onset event
2) VFC URL, username and password

Issue-ID: POLICY-57
Change-Id: Idc1d1fada295fa1c2e563ba37dd359f7b5c59f87
Signed-off-by: Ritu Sood <ritu.sood@intel.com>
6 years agoFix Sonar Blockers for Drools-Applications 39/8239/4
Mike Babinski [Tue, 22 Aug 2017 04:40:23 +0000 (04:40 +0000)]
Fix Sonar Blockers for Drools-Applications

Add null checks to protect against potential null exceptions.

Issue-ID: POLICY-111
Change-Id: Ib079d1b48a6858332ea3eaa0e75a991f518a0f9a
Signed-off-by: Mike Babinski <mb1915@att.com>
6 years agoMerge "Code cleanup to resolve critical sonar issues"
Pamela Dragosh [Sat, 19 Aug 2017 01:07:49 +0000 (01:07 +0000)]
Merge "Code cleanup to resolve critical sonar issues"

6 years agoCode cleanup to resolve critical sonar issues 65/7765/9
Magnusen, Drew (dm741q) [Wed, 16 Aug 2017 20:21:15 +0000 (15:21 -0500)]
Code cleanup to resolve critical sonar issues

Code cleanup mostly involed directing the output of exception messages
to the correct logger stream.

Issue-ID: [POLICY-115]
Change-Id: I2042bac3d3b0991a2ebed33421a73f1aa300c7c1
Signed-off-by: Magnusen, Drew (dm741q) <dm741q@att.com>
6 years agoMerge "installation improvements and renaming archetype"
Jorge Hernandez [Thu, 17 Aug 2017 21:11:59 +0000 (21:11 +0000)]
Merge "installation improvements and renaming archetype"

6 years agoinstallation improvements and renaming archetype 23/7923/1
Jorge Hernandez [Thu, 17 Aug 2017 19:46:36 +0000 (14:46 -0500)]
installation improvements and renaming archetype

Two changes:
- remove hardcoding of the DMaaP hosts, and DCAE topic to
  make it configurable.
- rename archetype to better name.

Change-Id: Ic50b9d1f06a138230c76cc6c50ca8072dc5da148
Issue-ID: POLICY-159
Signed-off-by: Jorge Hernandez <jh1730@att.com>
6 years agoRemove MojoHaus Maven plug-in from pom file 77/7777/1
Temoc Rodriguez [Wed, 16 Aug 2017 23:10:55 +0000 (16:10 -0700)]
Remove MojoHaus Maven plug-in from pom file

Remove MojoHaus Maven plug-in from main pom.xml file.

Change-Id: Ic336be3101860830010d1a395dd402771de85e88
Issue-ID: POLICY-116
Signed-off-by: Temoc Rodriguez <cr056n@att.com>
6 years agoMerge "Remove eclipse warning for duplicate version"
Jorge Hernandez [Wed, 16 Aug 2017 18:49:35 +0000 (18:49 +0000)]
Merge "Remove eclipse warning for duplicate version"

6 years agoPolicy-yaml changes 13/7613/3
Tarun Tej Velaga [Tue, 15 Aug 2017 13:20:02 +0000 (13:20 +0000)]
Policy-yaml changes

Changes to Policy-yaml and sdc projects based on changes from policy/engine.

Issue-Id: POLICY-88
Change-Id: Ic1a58f00029b9a66db6980fc7732a2ac57390229
Signed-off-by: Tarun Tej Velaga <tt3868@att.com>
6 years agoRemove eclipse warning for duplicate version 99/7599/1
Pamela Dragosh [Tue, 15 Aug 2017 13:24:47 +0000 (09:24 -0400)]
Remove eclipse warning for duplicate version

Duplicating managed version for maven-surefire-plugin 2.19.1

Issue-Id: POLICY-168
Change-Id: Ie48c2470e8d3938fc75049a867c32add9a4001d6
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years agoRemove eclipse checkstyle warnings 65/7465/1
Pamela Dragosh [Mon, 14 Aug 2017 17:41:44 +0000 (13:41 -0400)]
Remove eclipse checkstyle warnings

Add this should remove Eclipse warnings:
Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-checkstyle-plugin:2.17:check (execution: check-style, phase: process-sources)

Issue-Id: POLICY-166
Change-Id: Id0a4c0070f6190cd874a71b264f21ea16b0b583e
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years agoMerge "move packages build + tweaking pom.xml"
Pamela Dragosh [Wed, 9 Aug 2017 11:36:52 +0000 (11:36 +0000)]
Merge "move packages build + tweaking pom.xml"

6 years agomove packages build + tweaking pom.xml 27/7027/1
Jorge Hernandez [Tue, 8 Aug 2017 20:09:08 +0000 (15:09 -0500)]
move packages build + tweaking pom.xml

Change-Id: Iac032aa8f379cc8d614ec7913b41a68cbda9674d
Issue-ID: POLICY-162
Signed-off-by: Jorge Hernandez <jh1730@att.com>
6 years ago[POLICY-150] integration with oparent 93/6593/1
Guo Ruijing [Thu, 3 Aug 2017 10:32:01 +0000 (10:32 +0000)]
[POLICY-150] integration with oparent

Change-Id: I072b7dadb370f7065ae4bf39192fc73bbbb9682b
Signed-off-by: Guo Ruijing <ruijing.guo@intel.com>
6 years agoMerge "[POLICY-91] POM dependencies cleanup"
Jorge Hernandez [Thu, 27 Jul 2017 00:16:41 +0000 (00:16 +0000)]
Merge "[POLICY-91] POM dependencies cleanup"

6 years ago[POLICY-91] POM dependencies cleanup 89/6189/9
Gao, Chenfei (cg287m) [Mon, 24 Jul 2017 19:41:27 +0000 (15:41 -0400)]
[POLICY-91] POM dependencies cleanup

Change-Id: Idfc19a978be26e1dfa85736fea5ffecf6b298446
Signed-off-by: Gao, Chenfei (cg287m) <cgao@research.att.com>
6 years ago[POLICY-106] Removed unused function in the Guard project 43/6243/1
Michael Borokhovich [Tue, 25 Jul 2017 21:14:27 +0000 (17:14 -0400)]
[POLICY-106] Removed unused function in the Guard project

Change-Id: I4d19514525142c0b688f4811b5b92d0767a7d8bd
Signed-off-by: Michael Borokhovich <michael@research.att.com>
6 years ago[POLICY-110] Adding use case tests. 09/6209/1
Pamela Dragosh [Tue, 25 Jul 2017 13:50:22 +0000 (09:50 -0400)]
[POLICY-110] Adding use case tests.

Change-Id: Idac15a4678faf108dea6c12628b3f5ea351a8a17
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
6 years ago[POLICY-76] Remove/rename ATT internal stuffs 51/6151/3
Gao, Chenfei (cg287m) [Fri, 21 Jul 2017 21:03:44 +0000 (17:03 -0400)]
[POLICY-76] Remove/rename ATT internal stuffs

Change-Id: I251bd2c4f6852a563a4899024d138ebad6c52999
Signed-off-by: Gao, Chenfei (cg287m) <cgao@research.att.com>
6 years ago[POLICY-76] Remove/rename ATT internal stuffs 23/6123/1
Gao, Chenfei (cg287m) [Thu, 20 Jul 2017 20:45:26 +0000 (16:45 -0400)]
[POLICY-76] Remove/rename ATT internal stuffs

Change-Id: I3ec4fa22e22e9fccf4b6783b3bc8c92da25e181f
Signed-off-by: Gao, Chenfei (cg287m) <cgao@research.att.com>
6 years ago[POLICY-80] Adding the Policy Guard features 97/6097/4
Michael Borokhovich [Thu, 20 Jul 2017 13:53:57 +0000 (09:53 -0400)]
[POLICY-80] Adding the Policy Guard features

Two Policy Guard features added: Frequency-limiter and Blacklist.

Change-Id: I48184ab0ae9760c9ea7594cd7346b456aa964d48
Signed-off-by: Michael Borokhovich <michael@research.att.com>
6 years ago[POLICY-22] Update vFW+vDN filters to onap package 21/5821/1
Jorge Hernandez [Fri, 14 Jul 2017 18:38:57 +0000 (13:38 -0500)]
[POLICY-22] Update vFW+vDN filters to onap package

Change-Id: Ied53cb0454cb1669184c55a444233f4710870b7a
Signed-off-by: Jorge Hernandez <jh1730@att.com>
6 years ago[POLICY-22] gitignore autogened files 87/5787/1
Gao, Chenfei (cg287m) [Thu, 13 Jul 2017 14:39:06 +0000 (10:39 -0400)]
[POLICY-22] gitignore autogened files

Change-Id: I9777f3cc8ee61e6a55dba94bf455ff367814f762
Signed-off-by: Gao, Chenfei (cg287m) <cgao@research.att.com>
6 years ago[POLICY-22] Reorganizing drools-apps 99/5199/2
Gao, Chenfei (cg287m) [Thu, 22 Jun 2017 18:48:41 +0000 (14:48 -0400)]
[POLICY-22] Reorganizing drools-apps

Change-Id: I5f9bb3908f8d55c466dd847ae5e01a424e9ba364
Signed-off-by: Gao, Chenfei (cg287m) <chenfei.gao11@gmail.com>
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
7 years ago[POLICY-11] Sample Query with variable arguments 73/4073/1
Jorge Hernandez [Wed, 10 May 2017 05:07:39 +0000 (00:07 -0500)]
[POLICY-11] Sample Query with variable arguments

The sample drl query can be used in conjuction with the
REST API to externally retrieve/retract objects in the
KieSession working memory.

Change-Id: Ia6ca683988a0181a4846b57b0decca4668e74889
Signed-off-by: Jorge Hernandez <jh1730@att.com>
7 years ago[POLICY-11] remove redundant queries in drl 21/3921/1
Jorge Hernandez [Fri, 5 May 2017 14:55:17 +0000 (09:55 -0500)]
[POLICY-11] remove redundant queries in drl

Change-Id: I57d899ed497d664a54fef3039549cf231827f6c4
Signed-off-by: Jorge Hernandez <jh1730@att.com>
7 years ago[POLICY-11] Archetype based testing updates 17/3917/1
Jorge Hernandez [Fri, 5 May 2017 14:47:07 +0000 (09:47 -0500)]
[POLICY-11] Archetype based testing updates

1. Support for basic queries.
2. Updates to 1.1.0-SNAPSHOT

Change-Id: If68709177ae020ae7aabb1a33eed8ef5bd00a4ab
Signed-off-by: Jorge Hernandez <jh1730@att.com>
7 years ago[POLICY-10] remove external repo 49/3849/1
Pamela Dragosh [Wed, 3 May 2017 13:23:57 +0000 (09:23 -0400)]
[POLICY-10] remove external repo

Change-Id: I5f75433a32d2c7940e0bca6e47e02d6c209a7eee
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>