Age | Commit message (Collapse) | Author | Files | Lines |
|
Modified drools-apps to use XxxActor instead of XxxActorServiceProvider.
This is the second step of the rename.
Issue-ID: POLICY-2684
Change-Id: Iea60e92f914b7719ac765b086650479be9192d98
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
The Pair changes made in drools-pdp also broke drools-apps builds.
Replaced usage of drools.utils.Pair with apache Pair.
Issue-ID: POLICY-2202
Change-Id: I50aaad47c243637688602ae6cb680a929fe3edd9
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Issue-ID: POLICY-2188
Change-Id: Ib90222c537c5440e0de52fa0acbaa99bbcc4772a
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Now that the changes to the Actors have been merged, the former properties
can be removed, too.
Also fixed guard operator/operation name since it changed from "Guard"
to "Decision".
Issue-ID: POLICY-2629
Change-Id: I1c8d4575be598a8cab12b1aa4ad9b1d3e1f12113
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
In some conditions for assertTrue, sonarcloud
recommends using assertEquals
Assert.assertTrue(a.equals(b));
Assert.assertTrue(a == b);
Assert.assertTrue(a == null);
Assert.assertTrue(a != null);
Assert.assertFalse(a.equals(b));
Compliant Solution
Assert.assertEquals(a, b);
Assert.assertSame(a, b);
Assert.assertNull(a);
Assert.assertNotNull(a);
Assert.assertNotEquals(a, b);
Change-Id: Ic50bf6e961b74abcc698c2cc0347dd0472fefe71
Issue-ID: POLICY-2616
Signed-off-by: Taka Cho <takamune.cho@att.com>
|
|
Deleted Dbao and replaced it with the shared class in policy-models.
Also had to update the queries and the persistence.xml accordingly.
Note: with this change, the "database" project is no longer needed,
so it was deleted.
Issue-ID: POLICY-2581
Change-Id: Idfde68b28b3a27f2ee794fa477d15e0f12717373
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Modified drools-apps to generate the SDNR notification using the
SDNR-response provided by the actor in the operation outcome, instead of
using the controlloop-response provided in the operation outcome, as the
latter is deprecated.
Issue-ID: POLICY-2593
Change-Id: I70ee4a4b11345a4295d720250a63f407f51cb0bd
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
When the overall control loop times out, a notification is sent to
POLICY-CL-MGT, but then the event is discarded. Modified the code
to update the operation history, if an operation had been started,
and to generate an SDNR notification, if appropriate.
Applied the same logic for when a lock is lost.
Issue-ID: POLICY-2582
Change-Id: I35510ec8a3cfc6b2ca9be5751896f3c0f7d9bd09
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
If a request to SDNR times out, the actor class does not generate a
notification for the DCAE_CL_RSP topic. Rather than modifying the
actor, decided to modify models to handle that case. Seems like that's
where it belongs anyway, as notifications are more of an application-
level behavior.
Issue-ID: POLICY-2580
Change-Id: Id9426c223b719efce337a604316f19335dae8a94
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Mariadb is setting the "endtime" to the current time by default,
so rather than indicate a pending record using a null endtime, just
modified the code set "outcome" to "Started" to indicate a pending record.
Also added code to ensure the "outcome" is never null, as that causes
a DB error.
Also addressed a comment from a previous review to log a warning message
if more than one matching record is found in operations history.
Issue-ID: POLICY-2581
Change-Id: I6bf67551cef46808a79cc15afeb0abbfc1b6d945
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Modified code to insert a pending record when an operation starts.
Also modified it to update the existing record when the operation
completes, rather than adding a new record.
Note: the "outcome" for a "pending" record is left unset (i.e., it
is null).
Issue-ID: POLICY-2581
Change-Id: Ia1a02ed5a16b8af1328a49b22478fd57c4b9aca0
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Issue-ID: POLICY-2434
Signed-off-by: Jim Hahn <jrh3@att.com>
Change-Id: I1109a053e46dc8201ff9676da0c9ff93d8b631d5
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Frankfurt junits were generating the following output:
Value too long for column "TARGET VARCHAR(50)":
"'Target [type=VNF, resourceId=bbb3cefd-01c8-413c-9bdd-2b92f9ca3d38]'
The issue turned out to be caused by the fact that the rules for the
new actor were storing the "Target" instead of the "TargetEntity"
in the DB field. Modified the code to store the target entity, as the
the usecases rules do.
Issue-ID: POLICY-2441
Signed-off-by: Jim Hahn <jrh3@att.com>
Change-Id: I91ee517ef073e3dc3fea4698c814b57a06d87095
|
|
Flipped the flag(s) to enable guard checks in the various junit
tests for the Usecases and Frankfurt controllers. Note: the guard
checks use the guard simulator.
Modified new actor code to not include operation history on first
"guard denied" report (i.e., make it work like usecases does).
Issue-ID: POLICY-2434
Signed-off-by: Jim Hahn <jrh3@att.com>
Change-Id: I2897da4a0c8fb76fa00cb0f6cf8562c0703005d3
|
|
Fixed various sonar issues, including moving some
code to policy-common.
Fixed some eclipse warnings, including deprecated junit APIs.
Issue-ID: POLICY-2426
Signed-off-by: Jim Hahn <jrh3@att.com>
Change-Id: I10b40c1e5af62308f2e4c315e4d399aafff2998f
|
|
Also added VdnsTest, VfwTest, and VcpeTest.
Fixed a number of issues with notifications:
- event data (e.g., AAI) was missing
- notification was missing for the start of an operation
- "message" and "history" fields should contain Target object,
target entity
- "message" field was missing various details (e.g., start time)
Still missing subRequestId - that will require enhancements to
the actors.
Issue-ID: POLICY-2385
Signed-off-by: Jim Hahn <jrh3@att.com>
Change-Id: I7fc33ebcd5939d2f33a9d209ac6119e390e0836d
|
|
Note: VcpeTest and VfwTest are not included, as they depend on updates
to the APPC and APPC-LCM Actors.
Added feature-controlloop-frankfurt.
Added HTTP client property files to feature-controlloop-management.
Updates per review comments:
- pom changes
- simplify FrankfurtBase
- rename event-svc-http.properties
- change "usescases" to "frankfurt"
- use blanks for CDS property defaults
- trailing spaces in http-client files
- add https property to http-client files
Added newlines to config files that appear to be missing them (based
on feedback from gerrit).
Issue-ID: POLICY-2385
Signed-off-by: Jim Hahn <jrh3@att.com>
Change-Id: Ib4a4d75461c734ae47309e41dc9d099e8815d55d
|
|
Issue-ID: POLICY-2383
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
Change-Id: I5d5d864b2853f6e7e0c7e1096cb17746500f2495
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
|
|
Issue-ID: POLICY-2376
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
Change-Id: I362ebbd941c400a6ffc3e952e66ca2d624afbfdd
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
|
|
Tosca Compliant and Toscal Legacy Operational policies are
both supported for backwards compatibility.
vCPE usecase junits to support 2 equivalent policies,
one tosca compliant and the other one legacy.
Issue-ID: POLICY-2360
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
Change-Id: Iafbfc92bbec42e6a3fe4ceb4a9a17c85e636ea14
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
|
|
Issue-ID: POLICY-1587
Change-Id: I02bef6c829f2f24954ae73fb0c540ab7198775ce
Signed-off-by: Hockla, Ali (ah999m) <ah999m@att.com>
|
|
This class is only useful under drools applications and
eventually will be deprecated to accommodate the new
Operational Policy Types.
Issue-ID: POLICY-2146
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
Change-Id: I68927cb144a33fac6fe330be15fe60aee32b15a1
|
|
Removing all the related files and necessary modifications for removing named query. The code now only supports Custom Query.
Issue-ID: POLICY-2125
Change-Id: I2d376eb955d69f45c39ad4d4a1cfacb4d620ca8e
Signed-off-by: pramod.jamkhedkar <pramod@research.att.com>
|
|
Addressed the following sonar issues:
- unused imports
- unused method parameters
- superfluous "throws" declaration
- fields within a serializable class must also be serializable; this
was/will be fixed with a change to AaiCqResponse in policy-models
- use logger instead of System.out; turns out that the code that used
System.out is no longer needed. In fact, deleted several classes
that are no longer needed: ControlLoopLogger and ControlLoopPublisher
- cyclomatic complexity and switch/case statements too big; used
eclipse to extract chunks of code into separate methods
- duplicate code
Note: extracted common code and used lambdas to eliminate duplicate
code in PolicyGuardYamlToXacml. However, a better approach would be
to use object-oriented programming, using mini/nested objects to do
the generation. The lambdas would then become abstract methods.
Nevertheless, that would entail significantly more re-write of this
class than desired at this time
Issue-ID: POLICY-2225
Change-Id: Ie503ffd7accbad3e410af602d32b29c0095c3a33
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
https://gerrit.onap.org/r/#/c/policy/models/+/97989/
Issue-ID: POLICY-1896
Signed-off-by: Rashmi Pujar <rashmi.pujar@bell.ca>
Change-Id: I6125a1c83f58411f08bb143ff21ccd66d4db4977
|
|
Conditional checks for enrichment and validation by target-types
PNF specific AAI enrichment
Fixed Unit Tests
Issue-ID: POLICY-1187
Signed-off-by: Rashmi Pujar <rashmi.pujar@bell.ca>
Change-Id: I78bf73e454828253ca69695f9196047449b4d9d6
|
|
Updates to all references of APPC LCM model code
based on changes in policy models for APPC LCM.
Issue-ID: POLICY-2043
Change-Id: I0102eb27f449578636cfc0bf22124fa863f05724
Signed-off-by: Daniel Cruz <dc443y@att.com>
|
|
Modified code to use new Lock API.
Also deleted TargetLock and PolicyGuard, as they are no longer needed.
Issue-ID: POLICY-2113
Signed-off-by: Jim Hahn <jrh3@att.com>
Change-Id: I5bc9b7732f9cfc6056789b2902d9f6f838b560be
|
|
* Add request enrichment with aai service instance id and vnf id
* Implement cds grpc request
* Implement VfwControlLoopCdsTest
Issue-ID: POLICY-2088
Signed-off-by: Bruno Sakoto <bruno.sakoto@bell.ca>
Change-Id: Ib44d447d6a3a70ff800a5760032b676fdfa32d9c
|
|
Changes to the DRL file to change the rules to support custom query.
Added new VdnsControlLoop test for custom query, and supporting yaml
request
Issue-ID: POLICY-1858
Change-Id: Ic1b9e771bd36fe0642e9a3439189076a4906a4b8
Signed-off-by: pramod.jamkhedkar <pramod@research.att.com>
|
|
Due to sonar fixes, drools-pdp changed in a way that requires changes
to drools-applications. In the case of template.demo, lots of test cases
had to be modified, so they were refactored to extract common setup and
tear down code.
Fixed checkstyle issues.
Fixed license date.
Change-Id: Ie9e0239b95916ae7ef8c1b669987f7bb07d841b9
Issue-ID: POLICY-1968
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Fixed breakages due to changes made in policy/common to satisfy
sonar.
Repointed op.pom to correct parent, which allowed the other version to
be dropped and properties used in the rest of the pom.
Change-Id: Ib19c228c38b7f27fb9e9f508e5cf2566a8939cdd
Issue-ID: POLICY-1791
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Added coverage to:
- feature-controlloop-management
Fixed sonar issues, but didn't add coverage to:
- feature-controlloop-trans
- eventmanager
- guard
Change-Id: I12f09c4a533e838c6fb9762ba56194e51ce864eb
Issue-ID: POLICY-1791
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Modified the rules to set the operational timeout to the overall
CL timeout if the operational timeout is zero.
Added code to check for zero timeout for the overall CL, too.
Change-Id: I28d41632f59e9bc2fce953267883d567abc92a49
Issue-ID: POLICY-1859
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Per javadocs, getName() should generally be used instead of
Class.getCanonicalName(). This change only applies to classes; it
does not apply to File objects.
Change-Id: Ie402ab9239b2d5149c420d495f16bb82417d2d25
Issue-ID: POLICY-1646
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Handles the case where vserver name is not present in onset mesage.
Issue-ID: POLICY-1778
Change-Id: Ie7a1b9d207860a70b49309049b512fc8ce05a984
Signed-off-by: pramod.jamkhedkar <pramod@research.att.com>
|
|
BUILD_VERSION could not be used in ENV variable
as it is cooked in the base image itself. Need to
create a new one to reflect the drools build to
get by.
Some minor additional changes as to exit shell when
a docker command fails for clarity when executing
these operations is added as well.
Change-Id: Ic8dfc03bc0563c088d55b1991a0f8c431ab0fab2
Issue-ID: INT-998
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
|
|
Change-Id: Ia23a5b90b452bcafe2a8aa660598697ebfb07431
Issue-ID: POLICY-1691
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
|
|
|
|
Changes in event manager to support Aai custom query
Issue-ID: POLICY-1278
Change-Id: I693dd6b94f1fa6f24b08a389db099914636cf2ba
Signed-off-by: pramod.jamkhedkar <pramod@research.att.com>
|
|
Ensure database schema/naming consistent across repos.
Ensure PIP implementation consistent across repos.
Cleanup unused imports and made sure licenses are ok.
Issue-ID: POLICY-1471
Change-Id: I20a325fe3e66e6ae400e603ec366315aea716993
Signed-off-by: Joshua Reich <jreich@research.att.com>
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
|
|
Renamed enum class name and various method names in ControlLoopEventManager.
Change-Id: I18b4a7d30a24dfcf3b155fd662433590b9d4c769
Issue-ID: POLICY-1138
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Renamed classes from "SOxxx" to "SoXxx". Also renamed a few method
names to make them camelcase, too.
Updated drl files with above changes.
Change-Id: I06aa303a20911733f870947c55e01f3a2dc66fa3
Issue-ID: POLICY-1143
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Entails renaming VFCxxx classes and updated drl files, as well.
Change-Id: Ib31c61a35536df22772de6090761b22beb1b561b
Issue-ID: POLICY-1145
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Make test classes name consitence by adding 'Support' or 'Dummy' at start of util or dummy type of test classes
Issue-ID: POLICY-1258
Change-Id: Idea946375ee46f14512d4c4bc29e65adaa4d2b37
Signed-off-by: Parshad Patel <pars.patel@samsung.com>
|
|
Change-Id: I5d5acb9d71dc49eaa9fb397da5988ba3d8bd5f1d
Issue-ID: POLICY-1106
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Change-Id: Iee71481e357861618bed068f8b8ef37ec0ea2ab8
Issue-ID: POLICY-975
Signed-off-by: Joshua Reich <jreich@research.att.com>
|
|
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>
|
|
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>
|
|
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>
|