summaryrefslogtreecommitdiffstats
path: root/controlloop/templates/template.demo
AgeCommit message (Collapse)AuthorFilesLines
2018-11-16Remove unused imports in controlpolicykris.jinka8-41/+132
Remove unused imports that got introduced in recent commits Fix issue with compile failure of test class due to dependency in drools-pdp Datamodel classes. Fix test failures due to compile issues Issue-ID: POLICY-1251 Change-Id: Ib8e496ab96aaa5de67e4f84fa8de515b3dc22ea5 Signed-off-by: kris.jinka <kris.jinka@samsung.com>
2018-11-09Close timing loop-hole when YAML updatedJim Hahn5-0/+515
Noticed when YAML updates are pushed close together that some Params objects are deleted that should not be. Fixed that by eliminating the "active" list concept and only deleting a Params object that has an associated cleaner. If it has no cleaner, then it can't be deleted, regardless of timing with rule updates. Added more tests for rule updates, including cases to check for event objects being retracted, as well as Params objects being retracted when rules are deleted. Change-Id: I6b744b29fca228022f43e9322ea149b16d097675 Issue-ID: POLICY-1248 Signed-off-by: Jim Hahn <jrh3@att.com>
2018-11-05Cleanup all Param objects when any rules changeJim Hahn12-80/+542
Fix license date for new junit test. Updated some comments. Ensured different control loop names in different rule sets of new junit test. Used different mechanism for examining facts in new junit test. Fixed typo in comment. Changed the way new junit checks for existence of facts. Fixed another typo in comment. Updated clean-up rules in CLC template and added junit test to verify that Params are cleaned up appropriately. Removed code that retracts $manager objects so that the manager clean-up rule will be used, instead, thus ensuring that all associated objects are deleted when the manager is deleted. This was done for amsterdam, CLC, and casablanca templates. Added an extra fireAllRules() after calls to fireUntilHalt() to enable clean-up rules to fire in junit tests. Address Josh's review comments. Enhance junit test to compare actual object references to ensure that Param objects are as expected. Change-Id: If1fefd3f57e417180c62a3849defbaa6ae83afc1 Issue-ID: POLICY-1248 Signed-off-by: Jim Hahn <jrh3@att.com>
2018-11-02Merge "Re-added requestParams to vDNS policy"Pamela Dragosh1-0/+1
2018-11-02Re-added requestParams to vDNS policyJim Hahn1-0/+1
Undo inadvertent change to compiler test. Change-Id: I1973612f4783936271c3fd74fb978a4f263a14a9 Issue-ID: POLICY-1240 Signed-off-by: Jim Hahn <jrh3@att.com>
2018-11-02Merge "Upgrade xacml 1.0.2"Liam Fallon1-2/+2
2018-11-02Upgrade xacml 1.0.2Pamela Dragosh1-2/+2
This version of xacml only has license changes to the java source files. This will clear ONAP license issues. Issue-ID: POLICY-1228 Change-Id: Ieaff4d52c8046fee8357f7ebc907f2643d77322c Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2018-11-01Merge "Added config params to scale-out policy"Pamela Dragosh1-1/+3
2018-10-31Added config params to scale-out policyJim Hahn1-1/+3
Removed requestParameters and reverted name. Change-Id: Ia3470a751b22375206c571204eff8985e630e05f Issue-ID: POLICY-1240 Signed-off-by: Jim Hahn <jrh3@att.com>
2018-10-31Set new master version for Dublinliamfallon1-3/+2
Issue-ID: POLICY-1232 Change-Id: I6dfd85e9407c4d7400f593f035c627a303f397de Signed-off-by: liamfallon <liam.fallon@ericsson.com>
2018-10-25Fix refering to snapshot in drools-application1.3.1ramverma1-3/+3
Issue-ID: POLICY-1213 Change-Id: I91e4928e33d4e39286bf340e42602890446d9401 Signed-off-by: ramverma <ram.krishna.verma@ericsson.com>
2018-10-23Add CCVPN policyVidyashree Rama3-0/+406
CCVPN policy Issue-ID: POLICY-1209 Change-Id: I8adea233f8672c9ff43b4a169b50336d9e43c91d Signed-off-by: Vidyashree Rama <vidyashree.rama@huawei.com>
2018-10-09Add missing SDNC and fix JUnit1.3.0Pamela Dragosh1-6/+7
Identified in prior review, ensure all the new actors are in the appropriate pom.xml and minor fix to JUnit for assertEquals vs assertTrue. Issue-ID: POLICY-1191 Change-Id: I5c7505ad795e6e19c99a3aa9cec7ecf688da8316 Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2018-10-09Add implementation for OOF PCI use caseSaravanan A2-0/+458
Receive DMaaP message from PCI-Handler MS with PCI Config change recommendations through DCAE_CL_OUTPUT topic. Trigger SDN-R (if allowed by policy) by sending DMaaP request through SDNR-CL topic. When the response is received from SDNR through SDNR-CL-RSP topic, just parse and print. Code review comments addressed Added controller changes into amsterdam too. Change-Id: I93e54d3f44b4266092931a5f05b766cc26f2a869 Issue-ID: POLICY-1089 Signed-off-by: Saravanan A<saravanan.a75@wipro.com>
2018-10-05Add new actor SDNC to support CCVPN Closed LoopXin Miao1-0/+12
Issue-ID: POLICY-1183 Change-Id: I1b77b5b9cefca104382d9d84dd00bbd63b20e0f2 Signed-off-by: Xin Miao <xin.miao@huawei.com> Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2018-09-17Add demo for Control Loop Coordination.Joshua Reich1-1/+1
New PipEngine and Junit test added to guard. Also bug in existing Junit test fixed. All other code added to new directory template.demo.clc Change-Id: Ida2267528bcb9404dc59ff391d45797b591814cc Issue-ID: POLICY-1109 Signed-off-by: Joshua Reich <jreich@research.att.com>
2018-09-12Add implementation for OOF PCI use caseSaravanan A1-0/+12
Receive DMaaP message from PCI-Handler MS with PCI Config change recommendations through DCAE_CL_OUTPUT topic. Trigger SDN-R (if allowed by policy) by sending DMaaP request through SDNR-CL topic. When the response is received from SDNR through SDNR-CL-RSP topic, just parse and print. Code review comments addressed Change-Id: If340a23ae18367b7f98e31fe79c09a09e645b2ad Issue-ID: POLICY-1089 Signed-off-by: Saravanan A<saravanan.a75@wipro.com>
2018-08-29Fix remaining checkstylePamela Dragosh10-474/+701
Lots of formatting, missing javadoc, distance from use, imports must be explicit, ordering of methods. Fixed some abbreviation problems in classes and renamed JUnit tests to fix this. Issue-ID: POLICY-883 Change-Id: I8494f63d88d63c0232aca97f7bcc848816228fb1 Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2018-08-28Remove overriding dependencies warningsPamela Dragosh1-5/+1
With the move to oparent for dependencies, there are still some warnings in the pom's for overriding managed dependencies. Issue-ID: INT-619 Change-Id: I7ea771cc4536d8dfc77b4d1717e59cf6bfcfcda9 Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2018-08-15add prov-status check to AAI queriesJim Hahn3-1/+3
Also had to add prov-status field to AaiGetVnfResponse class. Removed bogus comment from test. Verify response is not null in test. Verify no requery by vnf name in test. Add prov-status to template.demo tests. Add prov-status to sample json for archetype-cl's. Change-Id: I3f36a2bb6de8265ce5b10103690d6d8813c15b1a Issue-ID: POLICY-964 Signed-off-by: Jim Hahn <jrh3@att.com>
2018-07-30Copy policy-endpoints from drools-pdp to commonmmis7-36/+42
Replaced references to classes deleted from drools-pdp with references to the corresponding in policy-common Issue-ID: POLICY-967 Change-Id: Ia9d2ac704e6b7c434e5a9e7aee6d7dcf9198e4f2 Signed-off-by: mmis <michael.morris@ericsson.com>
2018-06-05Update drools-applications to SNAPSHOT-1.3.0liamfallon1-1/+1
Snapshot updated for Casablanca. Issue-ID: POLICY-875 Change-Id: I0307282c4eabdb9ccd03282f918f4cd727ac4f86 Signed-off-by: liamfallon <liam.fallon@ericsson.com>
2018-05-21Update Drools Applcations to 1.2.3-SNAPSHOTliamfallon1-1/+1
These reviews must be merged in order because of layering. This review should be merged THIRD. Issue-ID: POLICY-844 Change-Id: I61d128f3244cd420abab15ab70c5c0e9d9afa625 Signed-off-by: liamfallon <liam.fallon@ericsson.com>
2018-05-16Upgrade SNAPSHOT to 1.2.2liamfallon1-1/+1
These reviews must be merged in order because of layering. This review should be merged FOURTH PLD added version.properties Change-Id: If7af7b3ae37166e88af92c0d1f1c558e5b60ab8e Issue-ID: POLICY-798 Signed-off-by: liamfallon <liam.fallon@ericsson.com> Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2018-04-16Add missing license headersPamela Dragosh17-0/+241
I removed a couple of empty README and added licenses. Issue-ID: POLICY-741 Change-Id: I10aad3536d02b738a1dc606f7311de6b3a2777cd Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2018-04-13Update to SNAPSHOT 1.2.1Pamela Dragosh1-1/+1
Issue-ID: POLICY-736 Change-Id: I2bc455510e925764d18a1d8e96e072bdadb251c6 Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2018-03-27Removed checkstyle warningsmmis5-805/+697
Removed checkstyle warnings from: policy/drools-applications/controlloop/common/model-impl/appc policy/drools-applications/controlloop/common/model-impl/appclcm policy/drools-applications/controlloop/common/model-impl/events including changes to template files due to renamed methods Issue-ID: POLICY-705 Change-Id: Ieb93baf43268aa608f204eef1a610354f2adec32 Signed-off-by: mmis <michael.morris@ericsson.com>
2018-03-26Fix path to logging classliamfallon4-4/+4
The package path of LoggerUtil changed as below: From: import org.onap.policy.drools.utils.LoggerUtil; To: import org.onap.policy.drools.utils.logging.LoggerUtil; Change-Id: I8187d97de5eeab92268baab155fb4de37f4df3ad Issue-ID: POLICY-448 Signed-off-by: liamfallon <liam.fallon@ericsson.com>
2018-03-01Remove CLM issues with commons-collectionsPamela Dragosh1-0/+9
We know that we are not configuring an LDAP PIP in our use of the XACML open source. The LDAP implementation uses Apache Velocity, which uses a very old version of commons-collections that has security issues. So we can exclude commons-collections from the build. Issue-ID: POLICY-504 Change-Id: I6d90731e601f58c8edaca6fe02df30ee2a090c2f Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2018-02-19Rename maven modules to mirror directory structureliamfallon1-180/+183
The naming of Maven modules in drools-applications was not aligned with the directory structure in the git repository of drools-applications. Therefore it was difficult to see the strucutre of the repository in Eclipse and other IDEs. This change amends the Maven module IDs to reflect the repository directory structure. This patch reset fixes the previos patch set, where many references to maven modules internally in drools-applciations were missed. See also changes in engine and docker repos. Updated to reflect repo directory structure in maven artifact groups. Issue-ID: POLICY-238 Change-Id: I8ab1a7ecdb664045222bbbfda269135e3e449109 Signed-off-by: liamfallon <liam.fallon@ericsson.com>
2018-02-11Tidy dependencies and scopes in POMsliamfallon1-12/+0
There were some duplicate dependencies in the POMs that were causing warnings. These have been removed. In cases where the revision of the duplicate dependencies were different,the latest revision was used. The scope of the "junit" dependency was "provided" in some POMs. These have been corrected with the scope of "test" being used for junit dependencies. Issue-ID: POLICY-238 Change-Id: Ib1cc6f040b0c4d7f2b39ae02bc6fb4590d395809 Signed-off-by: liamfallon <liam.fallon@ericsson.com>
2018-02-09Upgrade XACML jarPamela Dragosh1-2/+2
XACML was released with minor fixes for XML files with comments. Mainly it contained upgrade to dependencies that had fixed security issues. One still remains but will not be able to be fixed. Issue-ID: POLICY-616 Change-Id: Ifaf4f92d8da878a1c49dff5fd028744d01999ff5 Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2018-01-18Fix Tech Debt/JUnit on control loop event POJOsLiam Fallon5-215/+215
Mainly making fields private, fixing field and methods to follow Java guidelines, and adding getter and setter methods. Unit test added for all classes in org.onap.policy.controlloop Issue-ID: POLICY-455 Change-Id: I445b7cfaf9eb921a230bbb72b06ff4455fe003ce Signed-off-by: Liam Fallon <liam.fallon@ericsson.com>
2018-01-16Fix Sonar Technical Debt, Unit Test for APPC POJOsLiam Fallon2-4/+3
Mainly making fields private, fixing field and methods to follow Java guidelines, and adding getter and setter methods. Unit test added for all classes in org.onap.policy.appc Change-Id: If3db740bc146a09f8f7387f02c12b048ad00b201 Signed-off-by: Liam Fallon <liam.fallon@ericsson.com> Issue-ID: POLICY-455 Signed-off-by: Liam Fallon <liam.fallon@ericsson.com>
2017-11-21Bump minor versionJessica Wagantall1-1/+1
Bump minor version in preparation for Amsterdam branching. Change-Id: Ia7e97a72053a2d1cd10c0b9d5c179817c3ac7e23 Issue-ID: CIMAN-120 Signed-off-by: Jessica Wagantall <jwagantall@linuxfoundation.org>
2017-11-15Upgrade to 1.1.2-SNAPSHOTPamela Dragosh1-1/+1
Released 1.1.1, now must bump patch by 1 Issue-ID: POLICY-436 Change-Id: I3f5e4c369575f6fe1fa06cabb96a5bd43cb11087 Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2017-11-08Update SNAPSHOT versionPamela Dragosh1-1/+1
Releasing v1.1.0 so need to update version to 1.1.1 Issue-ID: POLICY-436 Change-Id: I8b85de39bb3a32f5f4faeeb4fcdfb5d95291ae31 Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
2017-11-03Fix Generic VNF isClosedLoopDisableddaniel1-5/+18
No A&AI queries will be done for enriched events. The event manager now understands prepended "generic-vnf." in front of is-closed-loop-disabled from DCAE onsets. A test case was revised to include sample data from an enriched onset with vnf data based on the VES documentation. Issue-Id: POLICY-350 Change-Id: Id7f59f8b860b9f147087067a2a9a7766f167f7e4 Signed-off-by: Daniel Cruz <dc443y@att.com>
2017-10-30Merge "Fix Final Failure on AAI Queries"Pamela Dragosh3-23/+17
2017-10-30Fix Final Failure on AAI Queriesdaniel3-23/+17
The drools engine will now send final failure notifications if there is an error returned from A&AI queries instead of rejected notifications. Issue-Id: POLICY-364 Change-Id: Ie9c22686d859c633bad47d223726957cc9599f7c Signed-off-by: Daniel Cruz <dc443y@att.com>
2017-10-27Send final failure on null vfc requestCharles Cole1-2/+57
Made sure a final failure is sent and the memroy is cleaned up if we cannot contruct a vfc request. Issue-Id: POLICY-350 Change-Id: Ia9bc827572042ae6ff2d2d2851d33034ee86fc49 Signed-off-by: Charles Cole <cc847m@att.com>
2017-10-27remove explicit call to shutdown in junitsJorge Hernandez6-15/+27
since it will exit the process immediately in a graceful case and affect junit execution. Change-Id: Ibcbb65269203e189515f68c557686c29667307e2 Issue-ID: POLICY-386 Signed-off-by: Jorge Hernandez <jh1730@att.com>
2017-10-25Fix Source/Target Lockdaniel3-2/+4
The locking of the target is now taken care of when the operation manager is initialized. This allows us to keep the template flow the same and to ensure that for vFW we will not lock the source if it is not intended to be the target. NOTE: This will have to be revised in the future if policy chaining will support having different targets specified for each policy in the chain. Additional work was done for hardening the APPC model code to make sure exceptions are caught and we gracefully end processing the event with memory clean up and a final failure notification sent. Issue-Id: POLICY-367 Change-Id: Ic796d95eb5400067744492f810dd8069ba6241b3 Signed-off-by: Daniel Cruz <dc443y@att.com> Signed-off-by: daniel <dc443y@att.com>
2017-10-24Change vnf-id to vnf-namedaniel2-13/+13
These changes now allow a lookup of the source vnf-id based on the onset's vnf-name. Issue-Id: POLICY-366 Change-Id: I6f6bd500b892dddbbb9e12156b4486208309e21d Signed-off-by: Daniel Cruz <dc443y@att.com>
2017-10-23Fix handling of aai 'get' errorsCharles Cole5-116/+310
Now reject an event if the AAI get query for the event fails. Added test cases for this behavior. Fixed some issues from my previous pull request. Issue-Id: POLICY-314 Change-Id: I674e95302a271423c307a88d061064e12e491a7a Signed-off-by: Charles Cole <cc847m@att.com>
2017-10-18Add support for AAI Named Query error handlingCharles Cole1-1/+95
Errors from AAI after a Named query now throw an AAIEXception. This is caught in the template to allow the resources to be removed from memory and a final failure to be thrown. Issue-ID: POLICY-314 Change-Id: I319d29ef537b2d01ca288622aac1d9dbbe05f5eb Signed-off-by: Charles Cole <cc847m@att.com>
2017-10-17Fix Target Entity Lockdaniel1-0/+399
This fix enables the pdp to stop events with different requestId's/controlLoopNames from being processed if the target entity specified is already being processed by another event/controlloop. The lock timeout rule is removed to stop the event from waiting to obtain a lock if it was not already required. Handling of the lock denied case is taken care of in the event manager rule instead of in a seperate rule to avoid further unneccessary computation. A new control loop test case was created that is for testing general control loop errors. The test case included is for testing that the lock will deny a request with a duplicate target entity. Issue-ID: POLICY-341 Change-Id: Ib62286eff74ec22b2c645f32f385cb331fb1dff3 Signed-off-by: Daniel Cruz <dc443y@att.com>
2017-10-17Fix operation history DB properties for JunitsTemoc Rodriguez1-0/+5
Removed operation_history.properties / operations-history.properties. Changed the properties in persistence.xml so that it uses the correct values. Previously junit would never write to db because the "guard.disabled" property was not set. Set this property. Additionally the operationshistory10 table was trying to be created even though it exists. These values work in junit code. Not tested on rackspace yet. Issue-ID: POLICY-345 Change-Id: Id755b3152ae6ac4991ea9c314154592ea0105070 Signed-off-by: Temoc Rodriguez <cr056n@att.com>
2017-10-11Enable junits to work with the archetype templateCharles Cole6-1295/+161
Control loop junits now use the actual PolicyEngine instead of a simulation, allowing them to work with the archetype template Issue-ID: POLICY-101 Change-Id: I910961996aaf831f4e91b7d7173d05fdfdd77683 Signed-off-by: Charles Cole <cc847m@att.com>
2017-10-06Fix Build Errorsdaniel4-8/+8
Removing the legacy "demo" project as this uses obsolete code. The operation and control loop timeouts were increased to allow more time for the simulators to respond. Issue-Id: POLICY-291 Change-Id: I1143352cefaf9749ca0eca55927960535b2599b8 Signed-off-by: Daniel Cruz <dc443y@att.com>