Age | Commit message (Collapse) | Author | Files | Lines |
|
Also added a "name" to the manager, for logger purposes.
Change-Id: Ide57cdec1fafc36c43b7f7584c0baad6261e8412
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
Change-Id: I7cc9baa21654e3d416a6ca1143f365ca295bf1d6
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Update missing information blocks and
indentation to pass verify job.
Change-Id: I0f514e9fb4a429addf40ba1171a8b7a363a070ae
Issue-ID: CIMAN-134
Signed-off-by: Jessica Wagantall <jwagantall@linuxfoundation.org>
|
|
Added a getter to allow the Gson object to be retrieved from a GSON
message body handler, useful for testing.
Moved the TextFileUtils utility class from APEX utilites to policy common
utils
Issue-ID: POLICY-1195
Change-Id: I7c8074e8177a90b292c6dfd6e7f0d352063818e7
Signed-off-by: liamfallon <liam.fallon@est.tech>
|
|
Change-Id: I64a997bbd1f21cb4eef134a1c474f8b5780dceb6
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
|
|
Migrate ECOMP Policy password encryption tool to ONAP
Issue-ID: POLICY-1561
Change-Id: I9020efb7698b95c36c4ebff842a318bf8beefc69
Signed-off-by: Joseph Chou <jc2555@att.com>
|
|
Added ServiceManager class to start a list of services, in order,
and stop them in reverse order.
Also addressed minor checkstyle issue in TopicSinkClient.
Enabled logging from tests.
Updated some comments.
Updated license date.
Added state checks and support for multi-threading.
Change-Id: Ie7f053d9884766fe199895691a57eb5a51b1d155
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Fixed issues in BeanConfigurator.
Fixed issues in NetworkUtil associated with newly added trust manager.
Change-Id: I0777ff85131d22c92c0ede06335a5b2839a1c482
Issue-ID: POLICY-1519
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
|
|
Added code to find available server ports.
Also added a trust manager that always trusts certificates.
Made trust manager private so we can allocate new ones in the future,
if we decide it isn't safe to re-use the same one over and over.
Modified test code to allocate a port rather than assuming 8180 was
not in use. Also modified retry parameters in other tests.
Added another allocPort() that takes an IP address and then modified
the other two to use that so the code does not have to be duplicated,
while providing more functionality.
Change-Id: I08cf18d923af46b1310d8496498bb1d4a0690b6e
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Classes that implement ParameterGroup all have to add their own
name and validate() fields and methods. Added an "impl" class that
provides the standard functionality and modified subclasses to use
it.
Change-Id: Ic6ee1607fb4fe7164a4e1eeebc480ea7d1e7e4d7
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
Modified the ParameterValidator to support new NotNull and NotBlank
annotations indicating that a field should not be null or blank.
These annotations can be made at class level or individual field level.
Moved annotations to their own subdirectory.
Added a comment to a method.
Extracted constant strings.
Moved one annotation to the subclass level.
Added support for "Min" annotation.
Propagate validation errors up from nested items. Apply
field-level validations, even when field is a ParameterGroup.
Change-Id: Ic90df55487dc5db7b7b0be5397624d1957904a81
Issue-ID: POLICY-1542
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
Removed PropertyConfiguration class, as it has been replaced by the
BeanConfigurator class.
Change-Id: If97a74fe81875d3eb85d7775ce78a7f2b1fb1f70
Issue-ID: POLICY-1444
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
1) Adding TopicSinkClient class for sending messages to topic. The same
class will be used for PAP->PDP & PDP->PAP communication.
2) Once this review is through, will raise another one to remove
PdpClient from policy/pap.
Change-Id: I7253683d9e88885cfbe2ac9041d01da239b9321b
Issue-ID: POLICY-1443
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
|
|
Refactored PropertyConfiguration, but left the original class alone
until references to it have been removed from other policy repos.
Split the Property annotation out into its own file. Cloned the
remaining code into BeanConfigurator, modifying its behavior so that,
instead of operating on its own subclass, it operates on a provided bean.
Also added an ability to copy the bean's fields to a Properties object.
Updated license dates.
Removed unneeded argument from functional interface.
Added comment about always checking default values.
Updated a few comments.
Change-Id: Iff36fd0524032d7630f9ee08f0eef7b05de100d1
Issue-ID: POLICY-1444
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Change-Id: I0d718ace3099bfa33508b11beece58447c0943ff
Issue-ID: POLICY-1444
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
1) Adding pdp-common module to policy/common. So that all common code
across various pdps will be at one place.
2) Adding java classes for PDP_STATUS, PDP_UPDATE, PDP_STATE_CHANGE &
PDP_HEALTH_CHECK messages.
3) Adding enums for PDPHeathStatus, PDPResponseStatus & PdpState.
4) Adding relevant test cases.
Change-Id: I13e62f393fbd1c261696783cfe4b7dfff72625ba
Issue-ID: POLICY-1443
Signed-off-by: ramverma <ram.krishna.verma@est.tech>
|
|
Added various listener classes to support dispatch by message type
and request id. The listeners are intended to form a pipeline:
TopicSource =>
MessageTypeDispatcher =>
RequestIdDispatcher =>
TypedMessageListener
Removed "PAP" from license.
Changed "handler" to "listener" in most places.
Simplified a test case.
Verified that no error message logged on success cases.
Removed println from test.
Updated some comments.
Change-Id: Ife265d14a6c5c8531601d9ce1343b88c1f8986a8
Issue-ID: POLICY-1444
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
Added StandardCoderObject to hide GSON's JsonElement so that classes
are not dependent on the use of JsonElement, making it easier to switch
out serialization mechanisms in the future.
Added a test for field-not-found.
Converted tabs to spaces in json test file.
Simplified StandardCoderObject and added methods to Coder for
translating to and from StandardCoderObject.
Removed a test for a method that no longer exists.
Added more tests to a test case.
Change-Id: I5123dc3f17c940ded431ef7f9ccd8c4bff6b1c5f
Issue-ID: POLICY-1444
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
The logger appender that's used in junit tests was getting the
raw message, which still had "{}" place-holders in it. Fixed that.
Split a test method to avoid checkstyle error.
Change-Id: I57571d8717aaee4adb7df186fe156501e9cc669e
Issue-ID: POLICY-1444
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
est.tech
Issue-ID: POLICY-1556
Change-Id: If83637b547d84b4caac6ad9b2b117d0051735c8c
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
|
|
Also:
Updated some comments and renamed a few parameters.
Removed a "throws" for a RuntimeException.
Short-circuit some calls.
Typo in comment.
Let gson create the JsonWriter.
Renamed a few more parameters.
Change-Id: I22e48c2191820c2a3d0743200edca79bd74353e7
Issue-ID: POLICY-1444
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
Added coder classes as a common utility that can be used to encode
and decode json data. Currently, it uses gson, but that can be
changed.
Separated the Coder interface from implementation.
Used assertSame to compare references.
Used numbers instead of strings so don't have to deal with escaping quotes
in the test cases.
Change-Id: Iea9001d2adc5a3150b3367619b5f43e96b5f8b41
Issue-ID: POLICY-1444
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
This class is used by the DAO model code being moved from
the APEX PDP to policy-models for generic DAO handling in the
Policy Framework
Issue-ID: POLICY-1264
Change-Id: I67cca540d9357f9ab16532090cb2edf397b332be
Signed-off-by: liamfallon <liam.fallon@est.tech>
|
|
Different gson providers may be used for REST APIs. Updated the code
to identify which was being used.
Change-Id: I8ffbda7409142ec728e217a87c9bcba3c34b814b
Issue-ID: POLICY-1428
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
This work allows a drools application, with its drl
template to refer to the topic name by its invariable
canonical name, ie. POLICY-CL-MGT. Since the drl
is a design time artifact, it is desired to know topics
by its canonical non-changeable name.
The actual per lab environment topic name may change
on a per deployment basis, for example POLICY-CL-MGT-WINDRIVER
or POLICY-CL-MGT-TLAB. The template can still use
POLICY-CL-MGT without modification but the actual installation
configuration would use the "effectiveTopic" property to
point to the right topic on a per lab basis.
This also helps with installation (long story) since
the canonical topics will be known ahead of time.
Change-Id: I8322bf7e427569c37a76eea5ce6d5b9547cb2ff3
Issue-ID: POLICY-1534
Signed-off-by: Jorge Hernandez <jorge.hernandez-herrero@att.com>
|
|
Removed most jackson dependencies from the policy-endpoints pom,
leaving jackson-annotations.
Moved jersey.version to top-level pom.
Change-Id: I73c6fef79d104ef62c7632ad3e02bc52865351cd
Issue-ID: POLICY-1531
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Added code to log a message when gson is used instead of jackson.
Change-Id: I8cbb8ad8461cc364c3419aaa174cef2680c5a672
Issue-ID: POLICY-1428
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
|
|
Removed some jackson references that are no longer needed.
Others remain; those must remain in place until they are no longer
needed by other policy repos.
Change-Id: Ica6624baf17be118714bb566c8db3ffce2c3587c
Issue-ID: POLICY-1428
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Some comments still said that including the maven artifact,
jersey-media-json-jackson, could override gson behavior, but
that is no longer true. The comments have been removed.
Change-Id: I9b6477b76f835b96c52ccb9777b80791fc6b1d77
Issue-ID: POLICY-1428
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Fixed issues with GsonTestUtils:
- don't set static from within a non-static method
- don't throw generic RuntimeException
Resolved checkstyle issue.
Removed trailing spaces.
Change-Id: If0c85733f62a24b56088dc90aadd4b95b3a6c91a
Issue-ID: POLICY-1428
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Added test for Serializer to increase junit coverage.
Added tests for TestTimeMulti to increase junit coverage.
Sonar fixes for PropertyConfiguration:
- use equalsIgnoreCase
- use the exception
Updated license dates.
Some fixes for LoggerFactoryWrapper to address sonar issue - utility
classes should typically have a private constructor.
Change-Id: I8957e9673fe8371ecca7abbb7ece87b0d6f46c1a
Issue-ID: POLICY-1519
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
The TypeAdapters in the gson-jackson code were nearly identical,
so a common class was factored out. This also enabled junit tests
to attain 100% coverage on that code, whereas there were a couple
of branches that could not be tested previously.
Addressed new sonar issues.
Removed unused import.
Change-Id: Id8e6460c881c6ce0239768f182e4e652cd10645f
Issue-ID: POLICY-1428
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
Added JacksonHandler which provides jackson behavior in gson.
Also added classes to facilitate testing of gson serializations.
Added compareGson(xxx, Class).
Removed trailing spaces from some files.
Updated license dates.
Replaced incorrect constant with ${xxx} in json test file.
Fixed typo in test method name.
Change-Id: If05b654d76a4ffc88646f03334be82b32506f28f
Issue-ID: POLICY-1428
Signed-off-by: Jim Hahn <jrh3@att.com>
|
|
|
|
|