Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
|
|
Change-Id: I389f61f9311bba35115a174c8526f897c98a3364
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Added another unused parameter from RequestImpl to a logging message.
Removed "throws PfModelException" from ProviderBase.
Shorten lambda function in SessionData.
Change-Id: I5c0ba99bd92ac94bdeacd2398fbc65f081ef85ad
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Change-Id: I46bc9b12d3edef995a2a04ee9a7fdc1830574bd5
Issue-ID: POLICY-1580
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
|
|
Moved methods into nested class of PdpModifyRequestMap. Note: they
will have to be moved back out when the broadcast capability is
added.
Removed extra "continue" from Publisher.
Rather than remove unused parameters and cause significant clutter
to the code, chose to use the parameters in a logger call for RequestImpl.
Removed unnecessary cast from UpdateReq.
Use version constant in PapRestControllerV1.
Log exception in PdpGroupQueryControllerV1.
Log exception in PdpGroupStateChangeControllerV1.
Shortened functional in PdpGroupDeleteProvider.
Removed unnecessary type parameters from PdpGroupDeployProvider.
Removed unneeded parameter and exception from ProviderBase.
Extracted common string from Main.
Shorted functionals in PapActivator.
Changed uses of getCanonicalName() to getName(); the former only has
limited use, while the latter is typically what is wanted and is
actually required whenever forClass(name) is used.
Fix junit tests broken by rename of ToscaPolicy version from
"typeVersion" to "type_version".
Change-Id: Ia00e1b3541c9e25b196a951e45681f67aa7f1bfe
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
The deploy/undeploy APIs used by CLAMP only pass the major number
when specifying a policy-version. Modified the code to handle
policy-versions of the form, major or major.minor.
Change-Id: I3251df162984f287bd1430b8e46da675b4c265ee
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Added code to support PDP group create/update & delete REST API calls.
The create/update request can also be used to deploy/undeploy policies.
It is assumed that the create/update request specifies a valid
list of supported policy types for each subgroup (i.e., PDP type).
Updated due to elimination of "version" from group in policy/models.
Added/updated junits.
Change-Id: I1916d9b17dfd5f12129c6f6a2fcf54e706662c10
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Modified the code so that, when a PDP is unable to fulfill a request,
an UPDATE is sent to the PDP with group=null and subgroup=null.
Also made updates to eliminate group version due to changes in
policy/models.
Change-Id: I9400ef5f8c365f492113a5b592b9ee6b7218756e
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
1) Adding code for initial PdpGroup/Subgroup creation.
2) Adding db configuration
3) Updated code as per change in policy/models
Change-Id: If37870925001b333e0537e364eecb266c351cf5a
Issue-ID: POLICY-1635
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
Modified code to update a PdpGroup, adding or removing policies, without
changing the version number.
Change-Id: I10031dff5f6d9c7e568605a8d73af6fe3c740901
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Several junit tests were broken when the json-encoded names were
changed for the fields within ToscaPolicyIdentifierOptVersion. This
review fixes those junit tests.
Change-Id: I963190b7792a2ebc3165ef04c74f4671c41c37da
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
The code to disable a PDP used the group name, extracted from a
prior PdpUpdate request, to identify the group from which the PDP
should be removed. This is not sufficient, as the requests tracker
may have never seen an update request. Therefore, the code was
modified to simply remove the PDP from all active groups. Also
made removeFromGroups(pdpName) public so that it can be used by
other PAP code.
Change-Id: Iedec88cb23e586944563dcc5ac82ff3b9f122f8c
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
|
|
|
|
Change-Id: Id744a7d49b9fb608ba3379dd43bcbd6a0297891f
Issue-ID: POLICY-1541
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
Change-Id: If3f01a6e92bef9eb889066115537f599e6b09229
Issue-ID: POLICY-1541
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Change-Id: I0c11b9704960f1b0b4d4c099a1b582ee259524e0
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Change-Id: I547f8a520d84d3593f90256fa91fc964c1d1e83c
Issue-ID: POLICY-1443
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
Refactored to facilitate the addition of broadcast requests in the
future.
Added disable-PDP capability.
Updated some comments.
Add junit tests.
Only treat null group as broadcast - empty strings are not broadcasts.
Added more logging.
Change-Id: I6f62b8755d20769c333f06752e9d63ac9ed83b57
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
1) Fixing review comments from previous review.
2) Adding updateLock to registration handler & state change provider.
Change-Id: I9f6e0de1f58190e490b28965c84a3a0c7aa90486
Issue-ID: POLICY-1443
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
1) Adding implementation of PdpGroup Query & State change providers for
PAP REST API.
2) Adding support for unregistering Pdp after recieving TERMINATED state
in PdpStatus message.
3) Updating PdpStatusMessageHandler with new filter changes in models.
4) Removing updatePdpStatistics method as we will implement db provider
and REST provider in next release.
5) Fixing few bugs found during Pdp registration testing.
6) Updating the existing test cases to work.
7) Will be adding more exhaustive test cases in another review.
Change-Id: I7aa20bf422671fdc1e06dab5e90aef4ee19a6a02
Issue-ID: POLICY-1541
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
Includes
1) Basic health and stats tests
2) Log analysis script
Change-Id: I6d8f7a0203251d9b685b89c4d0c8e19cd74c24c6
Issue-ID: POLICY-1460
Signed-off-by: Bilal A <bilal@research.att.com>
|
|
|
|
|
|
Policy/pap was still referring to models-pdp instead of
policy-models-pdp.
Change-Id: Ia39647a7fe3d29fe5d67ee6f8f57a296f4cc4347
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
PdpGroupFilter now supports filtering by latest version. Removed a
TODO from PdpStatusMessageHandler and added the filter parameter.
Change-Id: I67983397b616d8e289c4dc79d912bb4cf26e97ae
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
If an exception is thrown in the middle of processing policies, it's
possible for the DB to reflect a partial deployment. This change
queues the DB changes so that they're all made at once, after all
policies have been processed.
Extracted sort() into a common place.
Corrected some comments.
Simplified the list retrieval in the junits since all DB creates and
updates are now batched together into one operation each.
Change-Id: I835175fc16d4042c741d36ec69caa8f603d46d5a
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
Change-Id: I1158a6a7f0582dabafb22961d073db6d14cf2793
Issue-ID: POLICY-1443
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
Also moved the controller, the provider, and supporting classes
to their own dep_undep package.
Change-Id: Ifea1c4dd2ecbf93a8f4d45e130830cf9271103d3
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Changes made per the scrum call on 4/4 moved things around. In
addition, filter classes were added to the tosca provider. Both
of these necessitated changes to policy/pap so that things compile.
Change-Id: Iba4c52b650dab0f8d242b06be3fede42dd5b7264
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
1) Adding more code to pdp registration handler.
2) Fixing few broken files.
Change-Id: Ic8b68f95f7022ce0572345ea358ff380ec8a3e61
Issue-ID: POLICY-1443
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
Change-Id: I0ecef8f004967e2fffa33eff2ee7e6f035d3d94c
Issue-ID: POLICY-1443
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
1) Fix left over comments from previous review.
2) Change from PdpGroups to List<PdpGroup>
Change-Id: I833d4cf2837babf0947c9999220a651f9a69bf7e
Issue-ID: POLICY-1443
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
1) Adding PdpHeartbeatListener to keep listening for PdpStatus messages
coming from Pdp's over DMaaP either for registration or just heartbeat.
2) Adding PdpStatusMessageHandler to handle new Pdp registration and
also heartbeat coming from Pdp's.
Registration Flow -
1. Find the PdpSubgroup based on PdpType & SupportedPolicyTypes coming
in PdpStatus message.
2. If not found, don't register pdp and log the error message.
3. If found, check if PdpInstance is already added.
4. If not added, add PdpInstance to the subgroup and increment the
currentInstanceCount.
5. Create and send PdpUpdate & PdpStateChange message to the Pdp.
6. Update the changes in DB.
Heatbeat Flow -
1. Find the PdpInstance based on details in PdpStatus message.
2. Validate the details from message to what in DB.
3. If correct, persist the health & statistics information in DB.
4. If not correct, send a PdpUpdate & PdpStateChange message to the Pdp.
3) Unit tests will come as seperate review.
Change-Id: If705193259999e2ab077b78961282c998b949f57
Issue-ID: POLICY-1443
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
Somehow, pdpType is was still referenced by junit tests. Thought I
had fixed that, but guess not.
Change-Id: I8060208129cb2c6ba1ecb21d65efb778a2778aa5
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Added class to map between classes in models-pap and models-pdp.
Used constants in appropriate places.
Re-use maker functions.
Added some comment.
Corrected a comment.
Added mapping method for PdpDeployPolicies.
Added PdpDeployPolicies to "internal" package.
Updated to reflect refactoring of ToscaPolicy.
Fixed bug/typo in assertEquals test.
Updated tests to work with models-pdp not based on PfConceptKey.
Change-Id: I31cd4aaf58fa7dc39cea76349cc1337637a1b786
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Attempt to fix intermittent issues with junit tests for timer manager.
Eliminated duplicate method in junit test and renamed another method.
Always release a semaphore, just to be sure.
Logged different message depending whether timer is cancelled or expired.
Locked access to the current time to prevent the timer thread from
accessing it while registering a new timer.
Change-Id: Icb499acb18197fd8042eb186f88b61d5c30daeb0
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Change-Id: I573a345bcf69eb40782277f211fff2b7c69c4f55
Issue-ID: POLICY-1443
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
Added a DAO provider wrapper supporting a single create() method
to create a DAO provider. PapActivator registers it at start-up.
Commented out some junit timer tests that seem to fail intermittently -
doesn't impact code coverage.
Removed TODO from close() method.
Change-Id: Ie3abd7c7a4f9ffa7aa086609515a0bb3891585d9
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Added PAP DAO interfaces.
Added Publisher.
Added TimerManager.
Added RequestDataParams.
Added PdpModifyRequestMapParams.
Added RequestData.
Added PdpModifyRequestMapTest.
Updated timer test.
Extracted nested MessageData classes into their own files.
Addressed merge conflict.
Removed unneeded methods from PapActivator.
Fixed mismatchint action name.
Change-Id: I3aebef68a62b48d9154dd7a4c4ff366f9914717c
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Modified PapActivator to implement the Startable interface and used
that to manage it instead of the original method names.
Replaced pdp-common enums with models-pdp enums.
Added the use of the Registry.
Added parameters to be used for PDP interaction.
Added DAO interface classes.
Modified HTTP client, in junit tests, to use GSON instead of Jackson.
Removed DAO code, as the interfaces are not merged into policy/common
yet.
Added pdpParameters to default json config file.
Changed tabs to spaces in json files.
Removed "internal" classes that were moved to models-pdp.
Change-Id: I969a7747e926680ad403557b44a0a52d289fb6d9
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Change-Id: I861ace4811032314c3ce2c3f227f17354e127e5e
Issue-ID: POLICY-1541
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
Alpine OpenJDK was updated 2 days ago (3/14), this
upgrade seems to break java applications that depend on libnss*.so
OS libraries, which seem are no longer installed with the jdk.
Added some other libraries to aid when debugging
Change-Id: I0f5cbe5792038cf569940a1b32c109c9dd1e66cc
Issue-ID: POLICY-1604
Signed-off-by: Jorge Hernandez <jorge.hernandez-herrero@att.com>
|
|
|
|
|
|
Update missing information blocks and
indentation to pass verify job.
Change-Id: I03eecae246a9da24c82d60aae19cce12b1f62d0b
Issue-ID: CIMAN-134
Signed-off-by: Jessica Wagantall <jwagantall@linuxfoundation.org>
|