policy/apex-pdp.git
3 years agoUpdate jMeter test file 74/120074/1
arkadiusz.adamski [Wed, 31 Mar 2021 11:23:35 +0000 (12:23 +0100)]
Update jMeter test file

Issue-ID: POLICY-3093
Signed-off-by: arkadiusz.adamski <aadamski@est.tech>
Change-Id: If9600785d46bed5596847991690fe1631b97bbf3

3 years agoFix sonar issues 90/119890/3
arkadiusz.adamski [Wed, 24 Mar 2021 16:24:22 +0000 (16:24 +0000)]
Fix sonar issues

- reduce methods Cognitive Complexity from 19 to the 15 allowed in CommandLineParser
- iteration replaced with bulk 'Collection.addAll' call
- remove redundant initializers
- replace try with try-with-resources

Issue-ID: POLICY-3093
Signed-off-by: arkadiusz.adamski <aadamski@est.tech>
Change-Id: Ia727b3145ef8f63bcfc07723191c85e1ec8c923c

3 years agoMerge "Fix sonar issues"
Jim Hahn [Fri, 26 Mar 2021 19:17:39 +0000 (19:17 +0000)]
Merge "Fix sonar issues"

3 years agoMerge "Fix sonar issues"
Jorge Hernandez [Thu, 25 Mar 2021 13:29:02 +0000 (13:29 +0000)]
Merge "Fix sonar issues"

3 years agoFix sonar issues 91/119891/1
arkadiusz.adamski [Wed, 24 Mar 2021 16:55:39 +0000 (16:55 +0000)]
Fix sonar issues

- change test method name to avoid triggering SQ warning

Issue-ID: POLICY-3093
Signed-off-by: arkadiusz.adamski <aadamski@est.tech>
Change-Id: Id2997319e9986582a85f383c1f737340f4b4ea2c

3 years agoOverride to default entry point in apex-pdp 49/119649/2
Ram Krishna Verma [Tue, 23 Mar 2021 17:03:52 +0000 (13:03 -0400)]
Override to default entry point in apex-pdp

Overriding to default entry point (/bin/sh) in apex-pdp docker file to support stand alone installations of docker image.

Issue-ID: POLICY-3062
Change-Id: I100674cedf78f7221128bc87dd562835f297e0dd
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoFix sonar issues 47/119747/1
arkadiusz.adamski [Tue, 23 Mar 2021 18:29:25 +0000 (18:29 +0000)]
Fix sonar issues

- fix method name on ApexModel

Issue-ID: POLICY-3093
Signed-off-by: arkadiusz.adamski <aadamski@est.tech>
Change-Id: I853de0f48bbe683249b4c60c4189fb053c5c12a2

3 years agoMerge "Fixing issues around deploying APEX policies with duplicate concepts"
Jim Hahn [Tue, 23 Mar 2021 14:19:55 +0000 (14:19 +0000)]
Merge "Fixing issues around deploying APEX policies with duplicate concepts"

3 years agoMerge "Delete keystores from apex"
Ram Krishna Verma [Mon, 22 Mar 2021 21:45:22 +0000 (21:45 +0000)]
Merge "Delete keystores from apex"

3 years agoFixing issues around deploying APEX policies with duplicate concepts 59/119559/2
a.sreekumar [Fri, 19 Mar 2021 17:49:07 +0000 (17:49 +0000)]
Fixing issues around deploying APEX policies with duplicate concepts

Deploying invalid APEX policies with duplicate concepts resulting in
corrupting all the policies in memory. This is fixed here.
This entire functionality handling multiple policies will be
revisited as part of https://jira.onap.org/browse/POLICY-3018

Change-Id: I751102d5dddcb92cdcede8222855e2f467bb724d
Issue-ID: POLICY-3141
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoDelete keystores from apex 56/119556/1
Jim Hahn [Fri, 19 Mar 2021 16:51:26 +0000 (12:51 -0400)]
Delete keystores from apex

The Keystore is no longer needed in the tarball, as it is supplied
externally by the CSITs and Helm charts.  Deleted that file.
Also modified the junits to use utils-test to generates keystores at
runtime, thus deleted the junit keystore file, too.

Issue-ID: POLICY-3143
Change-Id: I9bb53fcb5887e73d661ec4c4083970630c61e5c1
Signed-off-by: Jim Hahn <jrh3@att.com>
3 years agoFixing parallel event execution problem in APEX-PDP REST layer 00/119500/7
a.sreekumar [Thu, 18 Mar 2021 12:39:46 +0000 (12:39 +0000)]
Fixing parallel event execution problem in APEX-PDP REST layer

Parallel event execution in APEX was resulting in incorrect dynamic REST url. This issue is fixed in this review.

Change-Id: Id8a28c001a7fd7915df1f5909109bb369667ab40
Issue-ID: POLICY-3019
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoMerge "Bump policy references to latest snapshot versions"
Jim Hahn [Thu, 18 Mar 2021 16:39:01 +0000 (16:39 +0000)]
Merge "Bump policy references to latest snapshot versions"

3 years agoBump policy references to latest snapshot versions 15/119515/1
liamfallon [Thu, 18 Mar 2021 15:46:21 +0000 (15:46 +0000)]
Bump policy references to latest snapshot versions

Issue-ID: POLICY-3105
Change-Id: I59daab64c4e36fc382d3c1c6a9f4ffe805ddc252
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoMerge "Increase code coverage"
Liam Fallon [Thu, 18 Mar 2021 14:29:12 +0000 (14:29 +0000)]
Merge "Increase code coverage"

3 years agoIncrease code coverage 99/119299/2
arkadiusz.adamski [Thu, 11 Mar 2021 10:09:10 +0000 (10:09 +0000)]
Increase code coverage

- increased test coverage in plugins-event-carrier-restserver package

Issue-ID: POLICY-3092
Change-Id: I10ad7f0dd24293de6ce426553c7bc7a2fe3be013
Signed-off-by: arkadiusz.adamski <aadamski@est.tech>
3 years agoUpdate policy-keystore with newer certificates 82/119382/1
jhh [Tue, 16 Mar 2021 15:29:52 +0000 (10:29 -0500)]
Update policy-keystore with newer certificates

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

3 years agoMerge "Increase code coverage"
Ram Krishna Verma [Mon, 15 Mar 2021 18:19:50 +0000 (18:19 +0000)]
Merge "Increase code coverage"

3 years agoIncrease code coverage 97/119297/1
arkadiusz.adamski [Thu, 11 Mar 2021 09:55:54 +0000 (09:55 +0000)]
Increase code coverage

- increased test coverage in the event.protocol.xml package

Issue-ID: POLICY-3092
Change-Id: Ie68f8acf49d258536ddc23a14d05302273687634
Signed-off-by: arkadiusz.adamski <aadamski@est.tech>
3 years agoBump apex-pdp to 2.6.0-SNAPSHOT 25/119225/1
liamfallon [Fri, 12 Mar 2021 09:23:56 +0000 (09:23 +0000)]
Bump apex-pdp to 2.6.0-SNAPSHOT

Issue-ID: POLICY-3105
Change-Id: I53abd7e9cf8c1425d115b0bb917db6389e9ded92
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoBump apex-pdp to 2.5.2-SNAPSHOT 65/119065/1
a.sreekumar [Wed, 10 Mar 2021 13:21:56 +0000 (13:21 +0000)]
Bump apex-pdp to 2.5.2-SNAPSHOT

Change-Id: I291f968367b1f864bb417a72fd0bdb22a07ba0f7
Issue-ID: POLICY-3127
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoRelease apex-pdp 2.5.1 docker 57/119057/1
a.sreekumar [Wed, 10 Mar 2021 12:16:21 +0000 (12:16 +0000)]
Release apex-pdp 2.5.1 docker

Change-Id: I9b5ee20c4760d4f9adcc28c708af62922d6952fa
Issue-ID: POLICY-3127
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoRelease apex-pdp 2.5.1 maven artifacts 52/119052/1
a.sreekumar [Wed, 10 Mar 2021 10:33:47 +0000 (10:33 +0000)]
Release apex-pdp 2.5.1 maven artifacts

Change-Id: Ib32e0a9dc3d3b9a27f712a02c0317bf7640bc12d
Issue-ID: POLICY-3127
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoPoint to policy-models 2.4.1 87/118987/1
a.sreekumar [Tue, 9 Mar 2021 18:03:40 +0000 (18:03 +0000)]
Point to policy-models 2.4.1

Change-Id: I142f196ddcd71048b6812af2d6af014ca42aa5a9
Issue-ID: POLICY-3127
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoUpdate info.yaml in apex-pdp 00/118400/1
Ram Krishna Verma [Wed, 24 Feb 2021 15:39:51 +0000 (10:39 -0500)]
Update info.yaml in apex-pdp

Issue-ID: POLICY-3028
Change-Id: Icf1319122ed19a0ba36b148bab7d77be626ba20e
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoBump apex-pdp to 2.5.1-SNAPSHOT 77/118377/1
a.sreekumar [Wed, 24 Feb 2021 13:40:41 +0000 (13:40 +0000)]
Bump apex-pdp to 2.5.1-SNAPSHOT

Change-Id: I761ded255a97128f858d3a7ce95f2479b6208a4e
Issue-ID: POLICY-3088
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoRelease apex-pdp 2.5.0 docker image 32/118332/1
Ram Krishna Verma [Wed, 24 Feb 2021 03:31:41 +0000 (22:31 -0500)]
Release apex-pdp 2.5.0 docker image

Issue-ID: POLICY-3088
Change-Id: Id5754dac1e8bab68cdb280800750ad98f14c76b1
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoMerge "Fixing intermittent test failures in APEX"
Ram Krishna Verma [Tue, 23 Feb 2021 20:45:51 +0000 (20:45 +0000)]
Merge "Fixing intermittent test failures in APEX"

3 years agoRelease apex-pdp 2.5.0 maven artifacts 13/118313/1
Ram Krishna Verma [Tue, 23 Feb 2021 19:45:50 +0000 (14:45 -0500)]
Release apex-pdp 2.5.0 maven artifacts

Issue-ID: POLICY-3088
Change-Id: Ifa746c534623e43f883f9101c4beb0f34dffbaac
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoFixing intermittent test failures in APEX 11/118311/1
a.sreekumar [Tue, 23 Feb 2021 19:07:08 +0000 (19:07 +0000)]
Fixing intermittent test failures in APEX

This review should fix the intermittent test failures in
TestExecutionPropertyRest class in APEX.

Change-Id: I1871a3ac1a40985ad44bbd1433c54930793c7b3c
Issue-ID: POLICY-3096
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoPoint to released version of docker, parent, common and models 69/118269/2
a.sreekumar [Tue, 23 Feb 2021 15:45:34 +0000 (15:45 +0000)]
Point to released version of docker, parent, common and models

Change-Id: I17e2e093421733fc94a3de8f5946b867b3b73ba9
Issue-ID: POLICY-3088
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoConvert Date to Instant in stats 20/118020/2
liamfallon [Wed, 17 Feb 2021 17:19:41 +0000 (17:19 +0000)]
Convert Date to Instant in stats

Issue-ID: POLICY-3069
Change-Id: Ib30782485652ec693d2dbea79514183c7cfbb0c4
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoMerge "Fix sonars in apex-pdp"
Ram Krishna Verma [Fri, 19 Feb 2021 17:42:41 +0000 (17:42 +0000)]
Merge "Fix sonars in apex-pdp"

3 years agoUpdate CSIT to check for 202 response during PAP Deployment 54/118054/2
a.sreekumar [Thu, 18 Feb 2021 15:51:32 +0000 (15:51 +0000)]
Update CSIT to check for 202 response during PAP Deployment

Change-Id: I947207f10cfd3bc54193ee7c8d356ad40587f072
Issue-ID: POLICY-2526
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoFix sonars in apex-pdp 39/118039/3
Jim Hahn [Wed, 17 Feb 2021 20:23:38 +0000 (15:23 -0500)]
Fix sonars in apex-pdp

Addressed the following issues:
- initialize mocks before use
- use parameterized queries
- Random() is not secure
- provide parameterized type for generics
- unused imports
- constructor visibility
- use compute() instead of containsKey()/put()
- make final fields static
- rename constants to all upper case
- no assert() in Thread.run() methods
- nested try
- nested if/else
- too many break/continue
- use try-with-resources
- repeatable annotations
- overlapping characters in reg ex
- hashcode is not sufficient in compareTo()
- need equals() with compareTo()
- make class an interface
- use parameterized test
- multiple calls in assert()
- log or re-throw
- use different type of lambda
- use parameterized logging
- use StringBuilder instead of concatenation
- use StandardCharsets.UTF_8

Issue-ID: POLICY-2906
Change-Id: I2cf8c885e3e22c2c6cbe6403a34906928afad022
Signed-off-by: Jim Hahn <jrh3@att.com>
3 years agoReplace GsonXxxAdapters 99/117999/4
Jim Hahn [Wed, 17 Feb 2021 21:07:33 +0000 (16:07 -0500)]
Replace GsonXxxAdapters

The GsonXxxAdapters were removed from the models Serialization classes
and replaced with type adapters from common.  Modified the code to refer
to the new adapters.
Without this fix, examples-onap-vcpe will not compile.  Could that be
the cause of the apex-pdp standalone issue, POLICY-3066?

Allow TypeAdapter in lieu of JsonSerializer/Deserializer adapters in
config files.
Note: examples-ona-bbs refers to the following, which were removed
several releases ago (during the actor re-write?):
- appclcm.util.Serialization$RequestAdapter & Serialization$ResponseAdapter

Issue-ID: POLICY-2905
Change-Id: Ia57e0346343614cbd4a1cffd9c8393f207284244
Signed-off-by: Jim Hahn <jrh3@att.com>
3 years agoFix jackson version in apex-pdp 61/117761/2
Jim Hahn [Thu, 11 Feb 2021 18:41:45 +0000 (13:41 -0500)]
Fix jackson version in apex-pdp

The kafka_2.12 jar depends on jackson-module-scala, but the default
version does not work with the version of jackson used by policy.
Modified the dependency tree to include a version that does work.

Issue-ID: POLICY-3005
Change-Id: I06fd5b99d6e5c1053e17a754f22f815062f907b2
Signed-off-by: Jim Hahn <jrh3@att.com>
3 years agomove csit to policy/apex-pdp repo 94/117694/2
Taka Cho [Wed, 10 Feb 2021 17:59:54 +0000 (12:59 -0500)]
move csit to policy/apex-pdp repo

move csit to policy/apex-pdp repo

Issue-ID: POLICY-2895
Change-Id: I73bd2f59c09f4ae213cab9b1dd2a83e909b218c6
Signed-off-by: Taka Cho <takamune.cho@att.com>
3 years agoChanges related to multi policy handling improvement in APEX 51/117651/8
a.sreekumar [Tue, 9 Feb 2021 18:21:49 +0000 (18:21 +0000)]
Changes related to multi policy handling improvement in APEX

This review fixes an issue identified during testing the changes done
for improving multiple policy handling in APEX.
Changes done to a few test files in the previous review are reverted as
well.

Change-Id: I98324da708239d314aadd4c45dc377137fd552ba
Issue-ID: POLICY-2883
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoRemove URL and useerid from JMS plugin 90/117690/3
liamfallon [Wed, 10 Feb 2021 14:01:23 +0000 (14:01 +0000)]
Remove URL and useerid from JMS plugin

This review makes the default URL and userid for JMS null, the actual
values must be specified as parameters.

Issue-ID: POLICY-3035
Change-Id: I9c06d94d8816092425e2df58b849d837ad953fb2
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoRemove security credentials from JMS plugin 76/117576/2
liamfallon [Sun, 7 Feb 2021 18:52:13 +0000 (18:52 +0000)]
Remove security credentials from JMS plugin

The default security credential of "password" was encoded in a constant
in the JMS plugin parameters file. This commit removes these credentials
and defaults the credentials to null.

Issue-ID: POLICY-3035
Change-Id: I6313340e64c893c4f99de78d9dd448ac53d81246
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoImprove handling of multiple policy in APEX PDP 02/117102/10
a.sreekumar [Mon, 25 Jan 2021 11:03:42 +0000 (11:03 +0000)]
Improve handling of multiple policy in APEX PDP

Change-Id: Ic4adf5bd8876dc31fc93993298e90389baaa2c39
Issue-ID: POLICY-2883
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoMerge "Add logs for REST request/response in APEX"
Ram Krishna Verma [Wed, 20 Jan 2021 19:04:51 +0000 (19:04 +0000)]
Merge "Add logs for REST request/response in APEX"

3 years agoUpdate Hazelcast version, remove security vulnerability 23/117023/1
liamfallon [Wed, 20 Jan 2021 15:38:04 +0000 (15:38 +0000)]
Update Hazelcast version, remove security vulnerability

Security vulnerabillitles were flagged in CLM in Hazelcast
version 3.11-BETA-1. Hazelcast version 4.1.1 removes that vulnerability.
The lock handling is slightly different in version 4.1.1 and the old
ILock class is removed. The code is updated to use the new FencedLock
locks.

Issue-ID: POLICY-2943
Change-Id: I0cb7d3cb279fed17b3f8758e55902703491f4b5c
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoAdd logs for REST request/response in APEX 21/117021/3
a.sreekumar [Wed, 20 Jan 2021 14:35:18 +0000 (14:35 +0000)]
Add logs for REST request/response in APEX

Change-Id: Ibf2cf19a1ec91473d8c655b87a712aa8738848c8
Issue-ID: POLICY-3003
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoAdd exception to logs 23/116923/1
Ram Krishna Verma [Fri, 15 Jan 2021 20:10:33 +0000 (15:10 -0500)]
Add exception to logs

Fixing the comments from previous review - https://gerrit.onap.org/r/c/policy/apex-pdp/+/116833

Issue-ID: POLICY-2885
Change-Id: I85474b365d92771e6e1b56bba95bde6e319d4ec2
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoAvoiding unwanted logging in APEX during event processing 87/116787/5
a.sreekumar [Wed, 13 Jan 2021 12:26:35 +0000 (12:26 +0000)]
Avoiding unwanted logging in APEX during event processing

Change-Id: If0c93bfea08025c6c10e3f4572a14088990f415f
Issue-ID: POLICY-2885
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoMerge "Changed identifiers to concept identifiers"
Liam Fallon [Wed, 6 Jan 2021 20:44:53 +0000 (20:44 +0000)]
Merge "Changed identifiers to concept identifiers"

3 years agoRemoving duplicate logging of single response event 30/116630/1
a.sreekumar [Wed, 6 Jan 2021 14:09:26 +0000 (14:09 +0000)]
Removing duplicate logging of single response event

Change-Id: I88c8f2eea9cb295e422d20222df21a46ef84cd4e
Issue-ID: POLICY-2885
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agouse jre base 2.2.0 - apex 08/116608/2
Taka Cho [Tue, 5 Jan 2021 20:06:16 +0000 (15:06 -0500)]
use jre base 2.2.0 - apex

use jre base 2.2.0

Issue-ID: POLICY-2917
Change-Id: I75ae9f401c3665cfad6bc9657511e8c59fe09d02
Signed-off-by: Taka Cho <takamune.cho@att.com>
3 years agoChanged identifiers to concept identifiers 72/116572/1
liamfallon [Mon, 4 Jan 2021 13:55:46 +0000 (13:55 +0000)]
Changed identifiers to concept identifiers

The policy models tosca classes ToscaPolicyIdentifier and
ToscaPolicyIdentifierOptVersion can be used to identify any TOSCA
concept, not just TOSCA policies so they are renamed to
ToscaConceptIdentifier and ToscaCinceptIdentifierOptVersion
respectively.

The class ToscaPolicyTypeIdentifier is redundant and is replaced by
ToscaConceptIdentifier.

Issue-ID: POLICY-2900
Change-Id: I5df89d023949cdf0f649951dbbd81a0b30f44ef6
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoMerge "Prune superfluous log and exception messages"
Liam Fallon [Mon, 21 Dec 2020 10:05:51 +0000 (10:05 +0000)]
Merge "Prune superfluous log and exception messages"

3 years agoPrune superfluous log and exception messages 43/116443/3
gregory.hayes [Wed, 9 Dec 2020 20:42:33 +0000 (20:42 +0000)]
Prune superfluous log and exception messages

Large volume exception messages should not be repeated in log messages
or in rethrown exceptions.

Link: https://jira.onap.org/browse/POLICY-2885
Issue-ID: POLICY-2885
Signed-off-by: gregory.hayes <gregory.hayes@est.tech>
Change-Id: I345531d3a7640cc5ad9dbfc367052b9c8cc19387

3 years agomove all bash to ash shell scripts - apex 46/116046/2
Taka Cho [Wed, 2 Dec 2020 20:27:04 +0000 (15:27 -0500)]
move all bash to ash shell scripts - apex

bash scripts convert to ash

Issue-ID: POLICY-2847
Change-Id: I4617223d4914820797f5ea121f75ee5f69a6ba40
Signed-off-by: Taka Cho <takamune.cho@att.com>
3 years agoMerge "Update vCPE example for JSON Stringify"
Jim Hahn [Mon, 16 Nov 2020 16:20:11 +0000 (16:20 +0000)]
Merge "Update vCPE example for JSON Stringify"

3 years agoMerge "Update gRPC example for JSON Stringify"
Jim Hahn [Mon, 16 Nov 2020 16:20:00 +0000 (16:20 +0000)]
Merge "Update gRPC example for JSON Stringify"

3 years agoApex CLI editor closes standard input/output/error 21/114921/2
liamfallon [Mon, 16 Nov 2020 12:13:58 +0000 (12:13 +0000)]
Apex CLI editor closes standard input/output/error

The Apex CLI editor closes its input and output when it completes. This is correct behaviour when the input and output are files. However, if the input and output are tied to standard input, output, and error then if there are subsequent actions in the JVM (Such as continuing to run Apex as we do in tests), then any output such as logging is lost.

This fix checks for standard input/output/error before closing the input
and output.

Issue-ID: POLICY-2897
Change-Id: Ifa20b62511f770197f30c4a817212a92876dd6a6
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoUpdate vCPE example for JSON Stringify 24/114924/1
liamfallon [Mon, 16 Nov 2020 13:13:43 +0000 (13:13 +0000)]
Update vCPE example for JSON Stringify

The JSON.stringify() call in the Rhino Javascript interpreter is not
working correctly. A previous patch introduced a method into the Apex
execution context to provide an alternative method for stringifying
JSON.

This patch updates the vCPE example in apex to use that new method.

Issue-ID: POLICY-2463
Change-Id: I85cc33dc4633b1b6f4c4db3d5ad8579c66d7c18c
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoUpdate gRPC example for JSON Stringify 22/114922/1
liamfallon [Mon, 16 Nov 2020 12:35:57 +0000 (12:35 +0000)]
Update gRPC example for JSON Stringify

The JSON.stringify() call in the Rhino Javascript interpreter is not
working correctly. A previous patch introduced a method into the Apex
execution context to provide an alternative method for stringifying
JSON.

This patch updates the gRPC example in apex to use that new method.

Issue-ID: POLICY-2463
Change-Id: I7f789c000d53dec60020fda2a6fccd71ef18edc3
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoAdd method to allow JSON conversion to execution context for logic 84/114784/5
liamfallon [Wed, 11 Nov 2020 11:13:34 +0000 (11:13 +0000)]
Add method to allow JSON conversion to execution context for logic

The Rhino JSON.Stringify() method does not work well. This patch allows
the user to call schema specific or generic JSON conversion using the
schema handling in Apex or not as the developer chooses.

Added a single argument stringify2Json() method.

Issue-ID: POLICY-2463
Change-Id: I9ec1e0dea2f6cd153b73b2eace63d8806674884d
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoStability test plan 50/114350/1
waynedunican [Wed, 28 Oct 2020 09:43:12 +0000 (09:43 +0000)]
Stability test plan

Update to apexPdpStabilityTestPlan.jmx file

Issue-ID: POLICY-2831
Change-Id: I76764e0614a523f2e58df04eed01111c59623e09
Signed-off-by: waynedunican <wayne.dunican@est.tech>
3 years agoPoint to snapshot versions 17/114317/1
Ram Krishna Verma [Tue, 27 Oct 2020 18:56:20 +0000 (14:56 -0400)]
Point to snapshot versions

Issue-ID: POLICY-2875
Change-Id: I8a7dbd9a1f8fbd88a94a85491304e0f75a05969c
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoBump apex-pdp master to 2.5.0-SNAPSHOT 92/114292/1
Ram Krishna Verma [Tue, 27 Oct 2020 17:58:46 +0000 (13:58 -0400)]
Bump apex-pdp master to 2.5.0-SNAPSHOT

Issue-ID: POLICY-2875
Change-Id: Ibb0e9a243bf92f0255cb5c145d31ccddb988fdf5
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoBump apex-pdp to 2.4.4-SNAPSHOT 61/114061/1
a.sreekumar [Tue, 20 Oct 2020 15:56:45 +0000 (16:56 +0100)]
Bump apex-pdp to 2.4.4-SNAPSHOT

Change-Id: I5e2cd92ee3620dea4070d9fa3aeb5ffd65f9412c
Issue-ID: POLICY-2869
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoRelease apex-pdp 2.4.3 docker 56/114056/1
a.sreekumar [Tue, 20 Oct 2020 14:51:24 +0000 (15:51 +0100)]
Release apex-pdp 2.4.3 docker

Change-Id: I08f7984cbc4f3b00f1720f21f27b6d019f90490e
Issue-ID: POLICY-2869
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoRelease apex-pdp 2.4.3 artifacts 44/114044/1
a.sreekumar [Tue, 20 Oct 2020 14:27:29 +0000 (15:27 +0100)]
Release apex-pdp 2.4.3 artifacts

Change-Id: I57e11b3993c2b97450ba8cd82872bcce466c2ee5
Issue-ID: POLICY-2869
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoPoint apex to models 2.3.5 30/114030/1
Pamela Dragosh [Tue, 20 Oct 2020 12:09:23 +0000 (08:09 -0400)]
Point apex to models 2.3.5

Issue-ID: POLICY-2869
Change-Id: I9880a3571da66390999f174ea2101a5e93280ac2
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
3 years agoMerge "Remove apex asciidoc documents"
Jim Hahn [Fri, 16 Oct 2020 14:17:43 +0000 (14:17 +0000)]
Merge "Remove apex asciidoc documents"

3 years agoRemove apex asciidoc documents 43/113943/1
liamfallon [Fri, 16 Oct 2020 12:09:11 +0000 (13:09 +0100)]
Remove apex asciidoc documents

Apex documentation has now all been ported to use the ONAP recommended
rst format. This review removes the old asciidoc documents.

Issue-ID: POLICY-2824
Change-Id: I562bd344cb7d6ff36e7d54bdb8f95e3b656468f8
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoBump apex-pdp to 2.4.3-SNAPSHOT 86/113686/1
Ram Krishna Verma [Thu, 8 Oct 2020 13:08:17 +0000 (09:08 -0400)]
Bump apex-pdp to 2.4.3-SNAPSHOT

Issue-ID: POLICY-2839
Change-Id: Ia7c847b3dafd28958d5df209af95cac19fa480a0
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoRelease apex-pdp 2.4.2 docker artifacts 58/113658/1
Ram Krishna Verma [Wed, 7 Oct 2020 22:41:57 +0000 (18:41 -0400)]
Release apex-pdp 2.4.2 docker artifacts

Issue-ID: POLICY-2839
Change-Id: I5b7ee8e97fd47896877e3eadc8ebb61e60b082fa
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoRelease apex-pdp 2.4.2 maven artifacts 55/113655/1
Ram Krishna Verma [Wed, 7 Oct 2020 21:48:29 +0000 (17:48 -0400)]
Release apex-pdp 2.4.2 maven artifacts

Issue-ID: POLICY-2839
Change-Id: I003109f4b999efaf57aba8a880f1800438baddf6
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoPoint to models 2.3.2 release 35/113635/1
Ram Krishna Verma [Wed, 7 Oct 2020 19:31:12 +0000 (15:31 -0400)]
Point to models 2.3.2 release

Issue-ID: POLICY-2839
Change-Id: Icb05b2c63cf760f8b8e02731e235041d7430a06e
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoRemove legacy operational policy type from apex-pdp 50/113550/1
Ram Krishna Verma [Mon, 5 Oct 2020 21:10:08 +0000 (17:10 -0400)]
Remove legacy operational policy type from apex-pdp

The legacy operational policy type for apex has been removed in Guilin release.
Removing it fron supported policy type and other places in apex-pdp.

Issue-ID: POLICY-2857
Change-Id: I41d58bf7e82292e11ff752f61dbe9be96a8a7af4
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoFixing APEX eventName handling to avoid duplicate requests 54/113254/6
a.sreekumar [Mon, 28 Sep 2020 11:45:22 +0000 (12:45 +0100)]
Fixing APEX eventName handling to avoid duplicate requests

Change-Id: I6ee50fb455424ae1f241b7a12d1cdbf0e6ee4011
Issue-ID: POLICY-2815
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoupdate default keystores 27/113127/1
jhh [Thu, 24 Sep 2020 19:52:14 +0000 (14:52 -0500)]
update default keystores

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

3 years agoCleanup related to removal of legacy format support in APEX 17/112817/3
a.sreekumar [Thu, 17 Sep 2020 11:02:19 +0000 (12:02 +0100)]
Cleanup related to removal of legacy format support in APEX

This review basically just removes all "policyModelFileName" occurences
which are not used anymore.

Change-Id: Ibac8ec776dd989a5d677ff27a99eb7a36110773f
Issue-ID: POLICY-2835
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoUse alpine base image 2.1.1 47/112647/1
Jim Hahn [Mon, 14 Sep 2020 22:09:01 +0000 (18:09 -0400)]
Use alpine base image 2.1.1

Issue-ID: POLICY-2819
Change-Id: I28b4c8acdef0302b6419a07c4445d60c398c4f73
Signed-off-by: Jim Hahn <jrh3@att.com>
3 years agoBump APEX version to 2.4.2-SNAPSHOT 01/112501/1
a.sreekumar [Thu, 10 Sep 2020 15:32:05 +0000 (16:32 +0100)]
Bump APEX version to 2.4.2-SNAPSHOT

Change-Id: Idde5050b425eb1bebe312e80e795c21513367a1b
Issue-ID: POLICY-2789
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoRelease APEX docker 2.4.1 90/112490/1
a.sreekumar [Thu, 10 Sep 2020 13:43:50 +0000 (14:43 +0100)]
Release APEX docker 2.4.1

Change-Id: Ief1025869ee480fe0d43063c2590d74c6de2c77d
Issue-ID: POLICY-2789
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoRelease APEX maven 2.4.1 83/112483/1
a.sreekumar [Thu, 10 Sep 2020 12:38:53 +0000 (13:38 +0100)]
Release APEX maven 2.4.1

Change-Id: I50a84d9abbb8563d1886f1ef199a79f1cc99b4ff
Issue-ID: POLICY-2789
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoDelete apex-client from packaging 40/112440/2
Jim Hahn [Thu, 10 Sep 2020 01:01:11 +0000 (21:01 -0400)]
Delete apex-client from packaging

The "stage-release" failed due to:
  18:51:12 [ERROR] Failed to execute goal
  org.apache.maven.plugins:maven-dependency-plugin:3.1.1:copy
  (copy-fat-jars) on project apex-pdp-package-full: Unable to
  find/resolve artifact. Could not find artifact
  org.onap.policy.apex-pdp.client:apex-client-full:jar:full:2.4.1
  in release-mirror (https://nexus.onap.org/content/repositories/public/)
  -> [Help 1]

Removed it from the package, as it is no longer part of apex-pdp.

Issue-ID: POLICY-2789
Change-Id: I4089096ab9668af33e885c70e140ce8fc1f51939
Signed-off-by: Jim Hahn <jrh3@att.com>
3 years agoRemove deleted dependency from apex-pdp 27/112427/2
Jim Hahn [Wed, 9 Sep 2020 21:39:17 +0000 (17:39 -0400)]
Remove deleted dependency from apex-pdp

One of the poms refers to core-deployment, which has been deleted from
apex-pdp.  Deleted it from the pom.

Issue-ID: POLICY-2789
Change-Id: Ie9d9265ad61808ca0d5dbf8ea3e772ac7348edbb
Signed-off-by: Jim Hahn <jrh3@att.com>
3 years agoPointing to released common & models 99/112399/1
Ram Krishna Verma [Wed, 9 Sep 2020 17:20:18 +0000 (13:20 -0400)]
Pointing to released common & models

Issue-ID: POLICY-2789
Change-Id: Ibaaf533f79cf2bc98090b2933392945ef8bb06ef
Signed-off-by: Ram Krishna Verma <ram_krishna.verma@bell.ca>
3 years agoAPEX standalone support for ToscaPolicy format 53/112053/15
a.sreekumar [Wed, 2 Sep 2020 16:19:26 +0000 (17:19 +0100)]
APEX standalone support for ToscaPolicy format

Legacy format support is removed, and Tosca format support is added.

Change-Id: I3cfc181ccb5471a5d224c0162af18c1fa0fdbc70
Issue-ID: POLICY-2812
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoMerge "Remove client code from apex-pdp"
Ram Krishna Verma [Tue, 8 Sep 2020 17:23:34 +0000 (17:23 +0000)]
Merge "Remove client code from apex-pdp"

3 years agopoint to 2.1.0 policy-alpine base - apex 68/112168/2
Taka Cho [Fri, 4 Sep 2020 12:52:15 +0000 (08:52 -0400)]
point to 2.1.0 policy-alpine base - apex

In G-rel, using 2.1.0 base.

Issue-ID: POLICY-2789
Change-Id: Ieff7433ab0c85abca218032a0a3c91bb42081a80
Signed-off-by: Taka Cho <takamune.cho@att.com>
3 years agoRemove client code from apex-pdp 64/112164/1
liamfallon [Fri, 4 Sep 2020 10:03:24 +0000 (11:03 +0100)]
Remove client code from apex-pdp

Removal of the deployment and monitoring client from the apex-pdp as
the functionality is replaced by the Policy Framework deployment using
PAP and the Policy Framework monitoring GUI.

Code in the engine proper that was used to administer apex-pdp over the
Web Socket port is also removed, as this code was only used by the
apex-pdp legacy GUIs.

Issue-ID: POLICY-2621
Change-Id: Ib9fc4a667a4bc79377bb7b82fae6a2bd520a3e3d
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoMerge "Sonar Bug fixes"
Pamela Dragosh [Thu, 3 Sep 2020 17:42:03 +0000 (17:42 +0000)]
Merge "Sonar Bug fixes"

3 years agoSonar Bug fixes 00/112100/3
waynedunican [Thu, 3 Sep 2020 11:56:54 +0000 (12:56 +0100)]
Sonar Bug fixes

Removal of remaining bugs in apex-pdp

Issue-ID: POLICY-2774
Change-Id: I370796e7c8a41c116155155c33176512e9e0cd91
Signed-off-by: waynedunican <wayne.dunican@est.tech>
3 years agoClean up warnings and SONAR issues 01/112101/2
liamfallon [Thu, 3 Sep 2020 12:32:01 +0000 (13:32 +0100)]
Clean up warnings and SONAR issues

Issue-ID: POLICY-2654
Change-Id: Ifd391ea9141d37cfd3ca4110d66c667962230ae1
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoSonar Build Fix 38/112038/1
waynedunican [Wed, 2 Sep 2020 12:12:45 +0000 (13:12 +0100)]
Sonar Build Fix

Issue-ID: POLICY-2611
Change-Id: I125e2e4be8e8f3f5e8bb67b282c134a51f1cd255
Signed-off-by: waynedunican <wayne.dunican@est.tech>
3 years agoJavaScript Sonar Coverage setup 82/111882/3
waynedunican [Mon, 31 Aug 2020 12:17:03 +0000 (13:17 +0100)]
JavaScript Sonar Coverage setup

Sonar properties added to apex-pdp in order to pick up JavaScript
coverage in SonarCloud

Issue-ID: POLICY-2611
Change-Id: Ia9c5837bc18a34722437b2b299e85c6a8a67088d
Signed-off-by: waynedunican <wayne.dunican@est.tech>
3 years agoUpdate apex JRuby joni dependency for security 40/111740/1
liamfallon [Wed, 26 Aug 2020 11:48:45 +0000 (12:48 +0100)]
Update apex JRuby joni dependency for security

Issue-ID: POLICY-2799
Change-Id: Ifdc16e99093995665db61329f61455fc0f327386
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoCorrect directory permission check in apex 35/111535/2
liamfallon [Fri, 21 Aug 2020 11:58:04 +0000 (12:58 +0100)]
Correct directory permission check in apex

Apex checked if the current directory is writable when it starts, it is corrected
to just check that the directory is readable and executable.

Issue-ID: POLICY-2791
Change-Id: I794f836cabfde0f6f78392b3c9e1de364d76e5f6
Signed-off-by: liamfallon <liam.fallon@est.tech>
3 years agoMerge "SONAR fixes - assert dissimiliar types"
Ram Krishna Verma [Tue, 18 Aug 2020 19:59:41 +0000 (19:59 +0000)]
Merge "SONAR fixes - assert dissimiliar types"

3 years agoMerge "Changes to make APEX container crash with non zero exitCode"
Ram Krishna Verma [Tue, 18 Aug 2020 19:57:14 +0000 (19:57 +0000)]
Merge "Changes to make APEX container crash with non zero exitCode"

3 years agoMerge "Remove apex policy editor gui"
Liam Fallon [Tue, 18 Aug 2020 10:18:13 +0000 (10:18 +0000)]
Merge "Remove apex policy editor gui"

3 years agoChanges to make APEX container crash with non zero exitCode 14/111314/3
a.sreekumar [Mon, 17 Aug 2020 10:29:16 +0000 (11:29 +0100)]
Changes to make APEX container crash with non zero exitCode

Change-Id: I1d36c28cfb07881ebede1cf918140397b076512c
Issue-ID: POLICY-2753
Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
3 years agoSONAR fixes - assert dissimiliar types 72/111272/3
waynedunican [Fri, 14 Aug 2020 10:24:14 +0000 (11:24 +0100)]
SONAR fixes - assert dissimiliar types

Fix for assertions comparing dissimiliar types.

Issue-ID: POLICY-2761
Change-Id: I1b2b8afa3e6308cda887d73a4ee079709847d054
Signed-off-by: waynedunican <wayne.dunican@est.tech>