Jim Hahn [Fri, 2 Nov 2018 18:19:30 +0000 (14:19 -0400)]
Re-added requestParams to vDNS policy
Undo inadvertent change to compiler test.
Change-Id: I1973612f4783936271c3fd74fb978a4f263a14a9
Issue-ID: POLICY-1240
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Thu, 1 Nov 2018 13:15:41 +0000 (09:15 -0400)]
Changed actor from "MSO" to "SO"
Also added "VF Module Delete" to the list of recipes for "SO" accepted
by the compiler.
Removed "AOTS" and "SDNO" from the list of accepted actors, as code does
not exist for those actors.
Update remaining actors and recipes. Left "AAI" in the list for now,
though it has no recipes listed (and no actor.aai code).
Also removed "AAI" from the list of accepted actors.
Change-Id: I9db56715d8bea3cf86d2112df1e0086777863192
Issue-ID: POLICY-1239
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Thu, 1 Nov 2018 00:47:41 +0000 (20:47 -0400)]
Remove single quotes from casablanca template
The shell scripts used to populate the operational policies for
the casablanca template do not work if the yaml includes single
quotes. Replaced the single quotes with %27 instead.
Change-Id: I31b20708b69153ecb67b7ac8136f464dbf2ce0c6
Issue-ID: POLICY-1240
Signed-off-by: Jim Hahn <jrh3@att.com>
Pamela Dragosh [Thu, 1 Nov 2018 00:45:20 +0000 (00:45 +0000)]
Merge "Added config params to scale-out policy"
Pamela Dragosh [Thu, 1 Nov 2018 00:44:53 +0000 (00:44 +0000)]
Merge "Add /serviceInstances/ to SO URL for scale-out"
Jim Hahn [Wed, 31 Oct 2018 23:19:02 +0000 (19:19 -0400)]
Added config params to scale-out policy
Removed requestParameters and reverted name.
Change-Id: Ia3470a751b22375206c571204eff8985e630e05f
Issue-ID: POLICY-1240
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Wed, 31 Oct 2018 22:09:19 +0000 (18:09 -0400)]
Add /serviceInstances/ to SO URL for scale-out
Also reformatted line that was subsequently too long.
Change-Id: I5c634c5157f18de64d37a0f451cd65f3002f35d3
Issue-ID: POLICY-1238
Signed-off-by: Jim Hahn <jrh3@att.com>
liamfallon [Wed, 31 Oct 2018 16:54:18 +0000 (16:54 +0000)]
Set new master version for Dublin
Issue-ID: POLICY-1232
Change-Id: I6dfd85e9407c4d7400f593f035c627a303f397de
Signed-off-by: liamfallon <liam.fallon@ericsson.com>
Jim Hahn [Tue, 30 Oct 2018 13:28:15 +0000 (09:28 -0400)]
Remove openecomp repo from pom
Change-Id: I896084627d9f3b726b543db87dbb6e30cf7922ef
Issue-ID: POLICY-1231
Signed-off-by: Jim Hahn <jrh3@att.com>
ramverma [Thu, 25 Oct 2018 10:59:09 +0000 (11:59 +0100)]
Fix refering to snapshot in drools-application
Issue-ID: POLICY-1213
Change-Id: I91e4928e33d4e39286bf340e42602890446d9401
Signed-off-by: ramverma <ram.krishna.verma@ericsson.com>
Vidyashree Rama [Thu, 18 Oct 2018 06:15:52 +0000 (11:45 +0530)]
Add CCVPN policy
CCVPN policy
Issue-ID: POLICY-1209
Change-Id: I8adea233f8672c9ff43b4a169b50336d9e43c91d
Signed-off-by: Vidyashree Rama <vidyashree.rama@huawei.com>
Pamela Dragosh [Tue, 9 Oct 2018 16:36:01 +0000 (12:36 -0400)]
Add missing SDNC and fix JUnit
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>
Pamela Dragosh [Tue, 9 Oct 2018 16:29:50 +0000 (16:29 +0000)]
Merge "Add implementation for OOF PCI use case"
Saravanan A [Tue, 9 Oct 2018 10:50:52 +0000 (16:20 +0530)]
Add implementation for OOF PCI use case
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>
Pamela Dragosh [Tue, 9 Oct 2018 00:53:48 +0000 (20:53 -0400)]
Remove unused endpoint dependency
This should have been cleaned out when we moved the code into
policy/common. The release job fails since it looks for a
non-existent release artifact for this.
Issue-ID: POLICY-1189
Change-Id: I46c95166ae47cf955cd43f0ce4af8dd40c0251fe
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
Xin Miao [Mon, 1 Oct 2018 23:09:24 +0000 (18:09 -0500)]
Add new actor SDNC to support CCVPN Closed Loop
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>
Pamela Dragosh [Tue, 2 Oct 2018 13:50:57 +0000 (09:50 -0400)]
Fixing sonar issues
Some trivial functional interface and ordering.
Added some missing JUnit tests.
Issue-ID: POLICY-1129
Change-Id: Iad6fe757a40819ca39e007b41dae1bf4b3f6cc0c
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
Pamela Dragosh [Tue, 2 Oct 2018 13:09:46 +0000 (13:09 +0000)]
Merge "Fix remaining sonar"
Pamela Dragosh [Tue, 2 Oct 2018 00:42:36 +0000 (20:42 -0400)]
Fix remaining sonar
Mostly moving variables to their right spot.
Issue-ID: POLICY-1129
Change-Id: Iccc084bbb404ffd51bdd0b26b5f8c373c6142fb1
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
Liam Fallon [Fri, 28 Sep 2018 11:06:43 +0000 (11:06 +0000)]
Merge "Add sdnr actor to archetype"
Pamela Dragosh [Fri, 28 Sep 2018 08:07:13 +0000 (08:07 +0000)]
Merge "Yet more sonar issues in drools-applications"
Jorge Hernandez [Fri, 28 Sep 2018 02:54:50 +0000 (02:54 +0000)]
Merge "Fix more sonar issues"
Pamela Dragosh [Thu, 27 Sep 2018 23:27:03 +0000 (19:27 -0400)]
Add sdnr actor to archetype
The casablanca template had the declaration. I made
sure the declarations were in the same place.
Issue-ID: POLICY-1155
Change-Id: Ie5ab7a04ffc0c3fefbc3edcea9e7a02a062f0dbe
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
Pamela Dragosh [Thu, 27 Sep 2018 16:28:19 +0000 (12:28 -0400)]
Fix more sonar issues
Most of these are minor issues along with a few others.
They have been bugging me so I thought I would get them
done. Some also do not show up on sonarlint.
Issue-ID: POLICY-1129
Change-Id: I31f2765f6babdfa80b23f0589daacc98da8d2002
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
Joshua Reich [Fri, 21 Sep 2018 23:44:25 +0000 (16:44 -0700)]
Yet more sonar issues in drools-applications
removed unused imports and variable definitions
moved variable declarations above methods
refactored deeply nested if/while
removed code smell due to unecessary use of static keyword
moved string literals to left side of comparator
fixed logging of exceptions
immediately return expression instead of assigning it to the temporary variable
Change-Id: Idfd2a2bdf3c2f3bbfcb54a06b713d57bc867b3ab
Issue-ID: POLICY-1129
Signed-off-by: Joshua Reich <jreich@research.att.com>
Jorge Hernandez [Thu, 27 Sep 2018 14:33:53 +0000 (14:33 +0000)]
Merge "Use powermock artifacts from parent pom"
Pamela Dragosh [Wed, 26 Sep 2018 17:53:38 +0000 (13:53 -0400)]
Fix for checkstyle declarations
I found the problem with policy-yaml. An exception was
occuring due to an extra line between an @return for
javadoc vs. just printing a warning.
See: https://github.com/checkstyle/checkstyle/issues/2398
I also messed up some of the other declarations in the
sub-modules.
Copyright
Issue-ID: POLICY-1153
Change-Id: I848e0b19340d494775e161bab86ffb60a97d83ab
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
Jim Hahn [Wed, 26 Sep 2018 14:41:48 +0000 (10:41 -0400)]
Use powermock artifacts from parent pom
Change-Id: I0b4f22e2bab30daee9efb12e6de427a93db8ae84
Issue-ID: POLICY-1148
Signed-off-by: Jim Hahn <jrh3@att.com>
Pamela Dragosh [Tue, 25 Sep 2018 10:47:53 +0000 (06:47 -0400)]
Fix sonar critical
Sonar complains that the password is an actual password when
in fact we are doing exactly the fix they suggest.
I seem to not have access to resolve it as a false positive.
So it seems the better way to do this is rename this to
reflect that it is actually a property value.
Had to also address 120> due to new variable name size.
Issue-ID: POLICY-1135
Change-Id: I2e2a36ed8d7f5c95e912df4f6ed74983cee8a3dd
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
Pamela Dragosh [Sat, 22 Sep 2018 00:08:11 +0000 (20:08 -0400)]
Fix checkstyle declarations
I fixed what I thought would be tolerable for this release.
Same issue as policy/common I had to defined the checkstyle
in each repo where the suppressions were needed.
Issue-ID: POLICY-1135
Change-Id: I8f30bee7e9cddc692ddad3cf88acedb2e6b4781b
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
Jim Hahn [Fri, 21 Sep 2018 20:55:04 +0000 (16:55 -0400)]
more sonar issues in drools-applications
Modified SO code to not return null lists for various buildXxxParam
methods.
Fixed commit message.
Added additional junit coverage to SO code.
Added additional junit coverage to SO code - cover more error cases.
Extracted another constant.
Change-Id: I65a27f2a1af1cfd8dd98bddab9ca1e862a3fa6fb
Issue-ID: POLICY-1129
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Fri, 21 Sep 2018 13:31:25 +0000 (09:31 -0400)]
new sonar issues in drools-applications
Don't return null lists from AAI.
Transient TargetLock.
Extract aai.url, et. al., constants.
Don't allocate extra unneeded variable.
Re-order fields in xacml attributes.
Extract "vserver" constant from simulator.
Replace thread sleep with join.
Change-Id: Iee1bd182862632af1f131cca5db5b526f5865b9f
Issue-ID: POLICY-1129
Signed-off-by: Jim Hahn <jrh3@att.com>
Joshua Reich [Fri, 14 Sep 2018 18:38:01 +0000 (11:38 -0700)]
Add demo for Control Loop Coordination.
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>
Pamela Dragosh [Mon, 17 Sep 2018 20:53:28 +0000 (20:53 +0000)]
Merge "remove volumeGroup from SO request"
Jorge Hernandez [Mon, 17 Sep 2018 20:31:03 +0000 (15:31 -0500)]
push-policies https for casablanca controller
https support for provisioning policies in
experimental casablanca controller
Change-Id: Ica711c10298f49b072c6a4f29a889e27cb851275
Signed-off-by: Jorge Hernandez <jh1730@att.com>
Issue-ID: POLICY-1120
Jim Hahn [Mon, 17 Sep 2018 19:09:23 +0000 (15:09 -0400)]
remove volumeGroup from SO request
After a new round of discussion with the SO team, it was learned that
the SO scale-out request should NOT include the volumeGroup in
relatedInstanceList[0]; that item should be eliminated altogether.
Re-ordered some imports.
Updated license date.
Left volumeGroup in TestDemo, as it's a pseudo VID request.
Change-Id: I94e82b7e8fe6a41695b99888f291e24b7103687d
Issue-ID: POLICY-962
Signed-off-by: Jim Hahn <jrh3@att.com>
Pamela Dragosh [Mon, 17 Sep 2018 15:51:05 +0000 (15:51 +0000)]
Merge "Option to disable target locking. Needed by CLC."
Liam Fallon [Mon, 17 Sep 2018 13:16:20 +0000 (13:16 +0000)]
Merge "Fixed sonar code smell"
Piyush Garg [Mon, 17 Sep 2018 02:46:56 +0000 (08:16 +0530)]
Fixed sonar code smell
removed unused method parameter aaiResponseWrapper from
constructDeleteRequest
Change-Id: Ie434130b040732ed4e656c5592fff5b049695d29
Issue-ID: POLICY-1079
Signed-off-by: Piyush Garg <piyush.garg1@amdocs.com>
Jim Hahn [Fri, 14 Sep 2018 20:30:51 +0000 (16:30 -0400)]
fix NPE from rule timers
This problem occurs in rules that have "timer(expr)" expressions before
the "when" clause. If a working memory element, other than the timer
object, appears in the "when" clause and is updated BY ANY RULE, then
an NPE is thrown. The solution is to segregate the objects so that
rules having "timer(expr)" expressions only refer to one object, the
XxxTimer object. In particular, the rule simply sets an "expired" flag
in the XxxTimer object and then all other rules check that flag, rather
than having their own "timer(expr)" expressions.
Corrected comment associated with rule TIMER.FIRED.
Change-Id: I9e6c20ee46af99234daee8ece4862edbd41ba714
Issue-ID: POLICY-1106
Signed-off-by: Jim Hahn <jrh3@att.com>
Joshua Reich [Thu, 13 Sep 2018 21:24:43 +0000 (14:24 -0700)]
Option to disable target locking. Needed by CLC.
When used, the ControlLoopEventManager will set useTargetLock to false
converting TargetLock lock/unlock operations to no-ops.
Allows CLC-specified logic to coordinate closed loops instead
of hard-coded mutual-exclusion enforced by target locking.
Change-Id: Ic067c1e1ce47b12d12742ed4bc04d59aa42751d6
Issue-ID: POLICY-953
Signed-off-by: Joshua Reich <jreich@research.att.com>
Jim Hahn [Wed, 12 Sep 2018 22:01:03 +0000 (18:01 -0400)]
implement Serializable in additional classes
Change-Id: I5d5acb9d71dc49eaa9fb397da5988ba3d8bd5f1d
Issue-ID: POLICY-1106
Signed-off-by: Jim Hahn <jrh3@att.com>
Saravanan A [Mon, 10 Sep 2018 12:01:33 +0000 (17:31 +0530)]
Add implementation for OOF PCI use case
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>
Jorge Hernandez [Tue, 11 Sep 2018 05:05:53 +0000 (00:05 -0500)]
disable http for drools apps using dmaap
per security guidelines ..
Change-Id: I1db4468f20c3bd22a9e5f27fefcb76b55a3b6d89
Signed-off-by: Jorge Hernandez <jh1730@att.com>
Issue-ID: POLICY-1105
Michael Mokry [Fri, 7 Sep 2018 21:46:20 +0000 (16:46 -0500)]
Added min and max vnf count support
Added variables for min and max with associated Constructor, getters and setters
We will need to merge this commit before merging the policy/engine
commit to avoid compilation errors in policy/engine build
Made changes to address Jim Hahn's comments
Change-Id: I45357077cfe046028adcc0033ecf29f8cc1a525b
Issue-ID: POLICY-1038
Signed-off-by: Mike Mokry <mm117s@att.com>
Piyush Garg [Fri, 7 Sep 2018 03:41:00 +0000 (09:11 +0530)]
Fix new sonar issue with vfModuleItem
find the last non-base vf module item from AAI response and use the same
to construct create or delete vf module SO request
Change-Id: I3b9b97ac3008f6e4f7952662d9e4262f77dbeec4
Issue-ID: POLICY-1079
Signed-off-by: Piyush Garg <piyush.garg1@amdocs.com>
Pamela Dragosh [Thu, 6 Sep 2018 00:27:03 +0000 (00:27 +0000)]
Merge "Added support for VF Module Delete recipe"
Jorge Hernandez [Wed, 5 Sep 2018 20:08:42 +0000 (20:08 +0000)]
Merge "Added junit test for commitAbatement."
Gabriel [Fri, 31 Aug 2018 09:20:43 +0000 (11:20 +0200)]
Add appc lcm request formatter
Formatter is used to dash case recipe in URL and camel case it in body.
Issue-ID: POLICY-1083
Change-Id: I908ae93665f3d069b3a032ae378b7775ebe1110a
Signed-off-by: Gabriel <adam.krysiak@nokia.com>
Joshua Reich [Sun, 19 Aug 2018 07:57:54 +0000 (00:57 -0700)]
Added junit test for commitAbatement.
Change-Id: Iee71481e357861618bed068f8b8ef37ec0ea2ab8
Issue-ID: POLICY-975
Signed-off-by: Joshua Reich <jreich@research.att.com>
Piyush Garg [Wed, 29 Aug 2018 10:10:53 +0000 (15:40 +0530)]
Added support for VF Module Delete recipe
Enhanced SOActorServiceProvider to support VF Module Delete Recipe.
Added SOOperationType enum to map the policy recipe with the SO API that
we want to call for a recipe. vf module id from non-base vf module is
used to construct the delete request url and same will be deleted.
Updated SOManager so that it sends request to SO based on the
SOOperationType enum value.
Enhanced RESTManager to add support for the http delete using new class
HttpDeleteWithBody (to allow pass the payload to the SO delete VF module API).
Change-Id: I15b678ed9ebc85dfa7cb62bbf23e41c0fe6e4c69
Issue-ID: POLICY-1079
Signed-off-by: Piyush Garg <piyush.garg1@amdocs.com>
Jim Hahn [Fri, 31 Aug 2018 20:26:05 +0000 (16:26 -0400)]
pass VF count to guard for scale-out
Also updated license dates.
Fixed new checkstyle errors.
Change-Id: Ia6153814c4333724185918f76be560aba5a52f96
Issue-ID: POLICY-1084
Signed-off-by: Jim Hahn <jrh3@att.com>
Joshua Reich [Tue, 14 Aug 2018 22:04:03 +0000 (15:04 -0700)]
Add code to store abatement events.
Stores abatement events in history DB.
Change-Id: Ifca6acd42cd9eea85e27765bd268a491028e305a
Issue-ID: POLICY-975
Signed-off-by: Joshua Reich <jreich@research.att.com>
Pamela Dragosh [Wed, 29 Aug 2018 11:58:53 +0000 (07:58 -0400)]
Fix remaining checkstyle
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>
Pamela Dragosh [Tue, 28 Aug 2018 15:57:33 +0000 (11:57 -0400)]
Remove overriding dependencies warnings
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>
Pamela Dragosh [Tue, 28 Aug 2018 15:22:22 +0000 (15:22 +0000)]
Merge "use new SO API for scale-out"
Jim Hahn [Mon, 27 Aug 2018 19:32:14 +0000 (15:32 -0400)]
use new SO API for scale-out
Updated licenses and serialization IDs.
Moved hashCode() and equals() methods to be in same location as in the
original code so it can be more easily compared.
Changed vDNS yaml timeout and retry to 1200 and 0, respectively, to match
the original values.
Removed extra newline from yaml, to match original yaml.
Reformatted source to wrap lines at 120 characters and removing trailing
white space.
Change-Id: I3f5e59a1f44750347de49164f587d4ffefdee8b4
Issue-ID: POLICY-962
Signed-off-by: Jim Hahn <jrh3@att.com>
Pamela Dragosh [Tue, 28 Aug 2018 13:57:31 +0000 (09:57 -0400)]
Change parent to policy/parent
Should be pointing to policy/parent rather than oparent
directly. This will automatically support upgrades more
easily. Also removing duplicated managed version override
warnings from Maven.
This is continuing work to support the integration effort
to consolidate common versions of java dependencies across
all projects.
Issue-ID: INT-619
Change-Id: I37ac20e669262d9ac8fff09fd1ac540190b47a30
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
Jim Hahn [Fri, 24 Aug 2018 18:00:30 +0000 (14:00 -0400)]
use new vf-walk code in SO request
Methods were added to AaiNqResponseWrapper to extract VF modules
and generate the new VF module name. This step modifies the SO
code to use those methods. It was also determined that the SO
code needs the VF module container object, not just the VF module,
itself. As a result, AaiNqResponseWrapper was modified to return
a list of the containers instead of a list of the VF modules.
Also modified the AAI simulator to return two VF modules in the
response to the vserver named query. As part of that, a method
was added to the simulator so that JSON responses can be read from
files rather than having to convert them to Java Strings.
Modified simulator to work even if vnf-id is null.
Change-Id: I68fdf07ea80ee0daf9e16403e35b11710315a8a8
Issue-ID: POLICY-1037
Signed-off-by: Jim Hahn <jrh3@att.com>
jh7358 [Thu, 23 Aug 2018 21:00:50 +0000 (17:00 -0400)]
walk VF module names
Added code to walk the VF modules to count the number of modules and
to generate the new module instance name.
Added comment to test method.
Fix checkstyle errors.
Read json files instead of resources.
Removed checkstyle plugin from aai pom, as it continues to barf every
time I use some automated feature of Eclipse.
Use Files.readAllBytes() instead of IoUtils.toString(uri).
Try concatenating file path.
Turned out to be a problem with file name case sensitivity - renamed
the file.
Change-Id: I1ce98d846dfa1d29e109b161c869108425d29771
Issue-ID: POLICY-1037
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Tue, 21 Aug 2018 19:54:11 +0000 (15:54 -0400)]
move AAI named query
The AAI vserver named-query was being done as a preliminary step for the
SO request. However, it will now be needed during the guard query, which
happens much earlier. Thus it has been moved from the SO classes into
the event manager class, where it is retrieved in a lazy fashion and
cached.
Also removed some trailing white space.
Update licenses.
Make test method private.
Change-Id: Id7353a2e0f2d42601d5142cb92961528fa21aa94
Issue-ID: POLICY-1011
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Thu, 16 Aug 2018 18:57:15 +0000 (14:57 -0400)]
fix new sonar issues with prov-status check
Changes made while adding the prov-status check triggered some sonar
thresholds in ControlLoopEventManager. Updated the code to resolve
them. One of the changes that had been introduced was to check for
the existence of both the is-closed-loop-disabled AND the prov-status
fields. However, if one is there then the other should be there, thus
the second check is redundant and was removed, which should reduce the
cyclomatic complexity back under the threshold.
Re-ordered the code a little, to make it less ambiguous.
Removed trailing white space.
Change-Id: If0ce74cedbf947c32cae3df3374cda6ba1305cd2
Issue-ID: POLICY-964
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Wed, 15 Aug 2018 20:34:02 +0000 (16:34 -0400)]
add prov-status check to AAI queries
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>
Jorge Hernandez [Wed, 15 Aug 2018 18:11:01 +0000 (18:11 +0000)]
Merge "Fix checkstyle issues"
Pamela Dragosh [Wed, 15 Aug 2018 15:20:09 +0000 (15:20 +0000)]
Merge "update AAI response classes per API"
Pamela Dragosh [Tue, 14 Aug 2018 18:22:34 +0000 (14:22 -0400)]
Fix checkstyle issues
Spacing, missing javadoc
Issue-ID: POLICY-883
Change-Id: Ice65c6c1baf0bb7c6273411f078bacfe3496b89b
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
Jim Hahn [Fri, 10 Aug 2018 22:16:21 +0000 (18:16 -0400)]
update AAI response classes per API
Several of the AAI response classes did not match the new AAI
interface. Updated AaiGetVnfResponse and AaiGetVserverResponse
and the classes they use to reflect the new API; other top-level
classes were left untouched.
Fix checkstyle errors.
Change-Id: Ife5830c45ba8aece8d676a10f0fd8a9c9fe6cb66
Issue-ID: POLICY-964
Signed-off-by: Jim Hahn <jrh3@att.com>
Pamela Dragosh [Mon, 13 Aug 2018 17:24:59 +0000 (13:24 -0400)]
Resolve checkstyle formatting
This submission is mostly focused on 120 spacing, missing
spaces, rearranged imports, newlines before package
and a few other items. Will have to submit further
reviews to finish this.
Issue-ID: POLICY-883
Change-Id: I772a2077ac97a0cb929810d8afadd2f415fae17b
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
Jorge Hernandez [Tue, 7 Aug 2018 14:11:39 +0000 (14:11 +0000)]
Merge "Fix basic code issues in controlloop"
Pamela Dragosh [Tue, 7 Aug 2018 13:01:11 +0000 (13:01 +0000)]
Merge "add scripts to measure performance of PDP-D"
Krishnajinka [Mon, 6 Aug 2018 05:18:00 +0000 (14:18 +0900)]
Fix basic code issues in controlloop
Found few issues while going through the code. Fixing
these issues in the controlloop package classes
Issue-ID: POLICY-1017
Change-Id: I24d0ce1257ad689c3e9d9b7a3bea07eeb65383f1
Signed-off-by: Krishnajinka <kris.jinka@samsung.com>
Jim Hahn [Mon, 6 Aug 2018 13:53:16 +0000 (09:53 -0400)]
carry forward template changes
Incorporated changes, to clean-up objects that have no associated Param
object, from the amsterdam rules template into the casablanca rules
template. Also carried forward changes in behavior of PolicyGuard
lock requests.
Fix typo in comment.
Change tabs to spaces and removing trailing spaces.
Change-Id: Ifcfda573f4c271d804e526d8cc0bea4b89b16612
Issue-ID: POLICY-955
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Thu, 26 Jul 2018 14:46:26 +0000 (10:46 -0400)]
add scripts to measure performance of PDP-D
Also changed tabs to spaces in scripts.
Fix typo in script name: "performace" -> "performance".
Add comments to uebtime.sh.
Removed comments about "wait".
Added "mt" to report script name.
Updated comments in both scripts.
Renamed jmeter script.
Modified uebtime.sh to scan zipped network files, too, and then combined
uebtime.sh into generate.sh.
Removed commented-out code from generate.sh.
Ignore errors from "ls network*.zip" in generate.sh.
Restructured the network.log parser and included additional request types
in the list of times it extracts from the log.
Removed unused import.
Rebased.
Removed unneeded network.log match pattern.
Added comments about matching abatements.
Renamed script to use hyphens instead of underscores, and dropped the
".sh" extension.
Change-Id: I5f8e74cec3e83d5427be03f5e684c871a038f923
Issue-ID: POLICY-888
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Thu, 2 Aug 2018 20:40:41 +0000 (16:40 -0400)]
rename rule template from beijing to casablanca
Changed assertTrue to assertEquals in CasablancaFeatureTest.
Change-Id: I3bec009ddde2f10468575b4b7bf9c08c24748aae
Issue-ID: POLICY-955
Signed-off-by: Jim Hahn <jrh3@att.com>
Jorge Hernandez [Sun, 29 Jul 2018 03:04:03 +0000 (22:04 -0500)]
https configuration for amsterdam controller
configuration set to false until unblocked by DMAAP-547.
Change-Id: I2efdafa8b143725fd73f05ec3d0a6a9ffc3b12c6
Issue-ID: POLICY-941
Signed-off-by: Jorge Hernandez <jh1730@att.com>
mmis [Mon, 23 Jul 2018 11:22:07 +0000 (12:22 +0100)]
Copy policy-endpoints from drools-pdp to common
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>
Jim Hahn [Mon, 16 Jul 2018 21:04:55 +0000 (17:04 -0400)]
Use refresh() instead of lock() in guard
This is the second step of separating the lock "refresh" operation
from the original "lock" operation.
Modified PolicyGuard to use refresh() to extend a lock. Also removed
the host name from the owner String, as it will no be longer needed
(once the final step is done).
Change-Id: I3a498e6f81d9dba1bbdfd6f7388087355192bcf5
Issue-ID: POLICY-872
Signed-off-by: Jim Hahn <jrh3@att.com>
Pamela Dragosh [Thu, 12 Jul 2018 12:20:17 +0000 (12:20 +0000)]
Merge "Username & password should be optional for VFC"
Jim Hahn [Wed, 11 Jul 2018 15:00:58 +0000 (11:00 -0400)]
Username & password should be optional for VFC
Also updated licenses.
Replace tabs with spaces in new junit method.
Updated licenses again.
Change-Id: Iebff19353c052e59bfd69da1677e9a05c44592a0
Issue-ID: POLICY-869
Signed-off-by: Jim Hahn <jrh3@att.com>
Jorge Hernandez [Wed, 11 Jul 2018 17:54:48 +0000 (17:54 +0000)]
Merge "Include hostname as part of lock owner"
Jim Hahn [Tue, 10 Jul 2018 20:29:13 +0000 (16:29 -0400)]
Catch exception from missing property in operation
When a new operation is started it will throw an IllegalArgumentException
if a property is missing. Modified the rules to catch this
exception, indicate the failure, and move on to the next operation.
Modified code to catch generic exception.
Change-Id: Ie8c24371eb84ee55ff0a0a5fcacda3670483efc5
Issue-ID: POLICY-869
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Wed, 11 Jul 2018 13:07:23 +0000 (09:07 -0400)]
Include hostname as part of lock owner
Because the lock owner string is constructed, using just the target type
and request ID, lock requests made by different ONSETs running on
different PDP-Ds may both succeed. Added the hostname to the owner
string so that locks for ONSETs for the same request ID will be rejected
if the request is made on different PDP-Ds.
Change-Id: I1d45194cbb1c5b1a1f6000477fe51879a2fecc19
Issue-ID: POLICY-872
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Fri, 6 Jul 2018 19:10:45 +0000 (15:10 -0400)]
Remove Params for deleted rules
If rules are deleted, then no rule is left to retract the
associated Params object. However, we can create more general
rules that will fire whenever rules are added, thus causing
clean-up of old Params at that time.
Implemented the above approach.
Change-Id: I207d493cc6924a4b34a8d0fa4915ed499ebc4a6e
Issue-ID: POLICY-872
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Thu, 5 Jul 2018 18:24:36 +0000 (14:24 -0400)]
Clean up objects for deleted rules
When rules for a closed loop are deleted, associated working memory
elements may be left around.
Modified the code to retract the various elements.
Re-added code to unlock when retracting TargetLock.
Add junit tests for new methods.
Forgot the junit test for request id.
Change-Id: Iec2805adbdb147a643f6163badee05ea353ada88
Issue-ID: POLICY-872
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Thu, 5 Jul 2018 14:36:49 +0000 (10:36 -0400)]
unlock should always return TargetLock
ControlLoopEventManager.unlock only returns the TargetLock if
the PolicyGuard.unlock operation is successful. However, if
the lock has already expired, then PolicyGuard.unlock will return
false, and ControlLoopEventManager.unlock will then return null.
As a result, the rules do not retract the TargetLock. (The rules
do, however, retract any left-over TargetLock objects during the
clean-up phase. Nevertheless, the earlier rules should not have
to depend on the clean-up rules to do that.)
Modified the code to address this issue.
Change-Id: I2e6099a4e3511053d2e6e1373cae4b480798d1b6
Issue-ID: POLICY-872
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Wed, 27 Jun 2018 15:04:11 +0000 (11:04 -0400)]
Add time limit to local guard locking facility
Modified the local policy guard locking facility to add
a time parameter.
Modified the control loop event manager to extend the lock
when lockCurrentOperation() is re-invoked.
Modified the rules to retract the lock if the lock request
was denied.
Reorder assertions in junit test.
Change-Id: Ic9b77acbb4881a5a516f30eb56664bad1a5c4d7e
Issue-ID: POLICY-872
Signed-off-by: Jim Hahn <jrh3@att.com>
Pamela Dragosh [Wed, 6 Jun 2018 15:46:56 +0000 (15:46 +0000)]
Merge "Remove Eclipse lifecycle error on plugin"
liamfallon [Wed, 6 Jun 2018 15:26:10 +0000 (16:26 +0100)]
Remove Eclipse lifecycle error on plugin
The kie-maven-plugin causes a lifecycle management
error in Eclipse (not in normal build). A profile
is added to the POM to remove this eclipse
error.
Change-Id: I6f5e5bec5e1e388edb083a910b9d1472af889a47
Issue-ID: POLICY-716
Signed-off-by: liamfallon <liam.fallon@ericsson.com>
liamfallon [Tue, 5 Jun 2018 15:41:35 +0000 (16:41 +0100)]
Update drools-applications to SNAPSHOT-1.3.0
Snapshot updated for Casablanca.
Issue-ID: POLICY-875
Change-Id: I0307282c4eabdb9ccd03282f918f4cd727ac4f86
Signed-off-by: liamfallon <liam.fallon@ericsson.com>
Jim Hahn [Thu, 24 May 2018 17:24:12 +0000 (13:24 -0400)]
Don't build credentials if user name is empty
Modified code to skip building credentials if user name
is empty, in addition to case where user name is null.
Change-Id: I5b53d4f97263df98cfe082f44a4e6af64b1e488b
Issue-ID: POLICY-868
Signed-off-by: Jim Hahn <jrh3@att.com>
Jorge Hernandez [Tue, 22 May 2018 17:56:44 +0000 (17:56 +0000)]
Merge "Update Drools Applcations to 1.2.3-SNAPSHOT"
Jorge Hernandez [Tue, 22 May 2018 16:47:41 +0000 (11:47 -0500)]
reduce transaction cache size
- reduce memory footprint
- avoid verbose logging from cache when
the object is not in the cache to
invalidate it.
Change-Id: I819cfbcfe32f5afdd238397c79ccd5cebd4534b8
Issue-ID: POLICY-852
Signed-off-by: Jorge Hernandez <jh1730@att.com>
liamfallon [Mon, 21 May 2018 14:35:55 +0000 (15:35 +0100)]
Update Drools Applcations to 1.2.3-SNAPSHOT
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>
liamfallon [Mon, 21 May 2018 14:58:38 +0000 (15:58 +0100)]
Add ID to stability test assembly
The <id/> tag was missing on the stability test assembly.xml. THis
caused the build of drools-applications to fail on Ubuntu 16.04 LTS
under maven 3.3.9.
Change-Id: I9689063068d9306e373161c15310eebe5e47a507
Issue-ID: POLICY-844
Signed-off-by: liamfallon <liam.fallon@ericsson.com>
Jim Hahn [Wed, 16 May 2018 22:07:23 +0000 (18:07 -0400)]
Fix authentication info in request to SO
The code was passing two different sets of credentials to the REST
manager, and the wrong one was taking precedence. Modified the code
to only pass the correct set of credentials.
Updated license date.
Change-Id: I13e2db93a8eebbb0cd77fdfaca80125cd28a2553
Issue-ID: POLICY-800
Signed-off-by: Jim Hahn <jrh3@att.com>
Pamela Dragosh [Wed, 16 May 2018 21:31:57 +0000 (21:31 +0000)]
Merge "Upgrade SNAPSHOT to 1.2.2"
liamfallon [Wed, 16 May 2018 13:50:40 +0000 (14:50 +0100)]
Upgrade SNAPSHOT to 1.2.2
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>
Jim Hahn [Wed, 16 May 2018 15:59:58 +0000 (11:59 -0400)]
Add prefix to make rule name unique
Change-Id: I3b04d6be4939cc2e652a676e7c2e4cb647f1bfec
Issue-ID: POLICY-796
Signed-off-by: Jim Hahn <jrh3@att.com>
Jim Hahn [Tue, 15 May 2018 20:08:59 +0000 (16:08 -0400)]
Add rule to cleanup onsets without Params
Change-Id: I0040a3be47d56808e2cda8a5ab2d3c1aa8e9fbb9
Issue-ID: POLICY-796
Signed-off-by: Jim Hahn <jrh3@att.com>
waqas.ikram [Fri, 11 May 2018 20:45:23 +0000 (21:45 +0100)]
Fix error stability test jmx file
Change-Id: Ideb306e12b5cd8e65f2a894371942aeff1ddfebc
Issue-ID: POLICY-525
Signed-off-by: waqas.ikram <waqas.ikram@ericsson.com>