Age | Commit message (Collapse) | Author | Files | Lines |
|
Issue-ID: AAI-2281
Change-Id: I0f5cce16ce76113b1fee603ad3c191cb6f9fe80f
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Refactoring of the software version extraction routines to reduce
complexity.
Pass the NodeTemplates directly to the extractSoftwareVersions() method
and move the exception handling up the calling stack.
Remove the creation/usage of an intermediate Pair object.
Query for the Service VF list once only.
Use Streams rather than converting from Stream to List and back.
This change will simplify future work: either to convert sdc-tosca API
methods (that will be deprecated), or to use an alternative parser.
Change-Id: I745ced9e6095f389ee1bede37e8480dfaf65716a
Issue-ID: AAI-2281
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Increase code coverage
Change-Id: I7eb50720fb20ce44ff87c0011e784a77606cf9ff
Issue-ID: AAI-2280
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Add new tests to give better coverage of the authorization classes.
Refactor the core class for readability.
Change-Id: I2be467d8f4492249a0c29be8b108bb2bce2818dd
Issue-ID: AAI-2229
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Test an uncovered code path. Remove the unnecessary declaration of the
Jetty OBF: prefix constant String. Ensure that the Spring Application
exits before the next JUnit test runs.
Change-Id: Iceb2e79a923359c15ca6ad366c2ac94a63e381b0
Issue-ID: AAI-2229
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Replace this with a WidgetType dynamic enumeration, which may be
extended at runtime. Load the Widget Types from the mapping
configuration (JSON file).
Issue-ID: AAI-2229
Change-Id: I5d1bc4291b4446f6d744821bf1d74b1f117b901f
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Improve code coverage to address Sonar code smells.
Include a dummy keystore file to allow the Spring Boot Application to
start up without error.
Change-Id: Ifab33a67e5d051baacfad91d3f317a8fb8b0a669
Issue-ID: AAI-2212
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Refactor the Model/Service/Resource/Widget hierarchy to improve code
readability.
Replace the configurable Boolean value for a Resource's model type with
a value from the existing ModelType enum.
Obtain the A&AI XML Model name (always resource or service) directly
from the Model class and not from the configured model type for the
Resource.
Change-Id: I1487d919392b34e4bf1314da8cd2805a9fbf96a3
Issue-ID: AAI-2212
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Delete methods that are never called (or only called from test code)
Issue-ID: AAI-2212
Change-Id: I1554bd76de4a9ac2e3cc05987dac1d04966b9200
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Add a test to improve code coverage. Also tidy up some out of date test
code comments and unnecessary structural code.
Change-Id: Ib38a3d602bc5ae46d16f3067d1d3e0ba0838c446
Issue-ID: AAI-2212
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Add Javadoc and make cosmetic changes to prevent Checkstyle messages
Change-Id: Ibab7be42d6a01b181cdb625b6b34d580658c7046
Issue-ID: AAI-2212
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Extend the TOSCA mappings JSON content by adding a set of of Widget
types defining the type name and data-delete flag. In this change the
set of supported types (defined by an enum) remains. However the
intention is to replace this in a future commit.
The hierarchy of annotated Widget types is replaced by this new
configuration, which is accessed from the Widget class.
Refactoring has been kept to a minimum to simplify the code review
process but further improvements can now be made.
Ideally the set of supported Widgets can be extended through
configuration changes only.
Change-Id: I005cfe6976778b14f14c3ad06d8acf3745c8dd8f
Issue-ID: AAI-2212
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Change-Id: I9699ee13321f136b4460d5c85d49ab13378f52b4
Issue-ID: AAI-2121
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Rename the System Property to be tosca.mappings.config and default the
value to ${CONFIG_HOME}/tosca-mappings.json
Update Java code and comments to remove the word "filter" where this is
now outdated.
Add new JUnit tests for better code coverage.
Change-Id: Iaa9685638e099c898894171a958b0d5d51542fde
Issue-ID: AAI-2121
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Minor code tidy-ups: mostly formatting and Javadoc comments
Change-Id: I8a9ab692428fa09c73bd1fb542100610a86f6eca
Issue-ID: AAI-2121
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Delete the sub-classes of the Resource (internal Model class) and
replace the annotated properties of these classes with TOSCA-to-Model
mappping data loaded from the JSON configuration.
Change-Id: I56d5d9d4893be45eb42ae65099ea9abe5f4409b9
Issue-ID: AAI-2121
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Change the filter-types.properties file: re-implement to use JSON
content. Remove the System Property that defines the location of the
file and add this to the Spring application properties.
Initialise the type-to-model mappings using the key=value pairs from
this JSON content.
Refactor existing Junit tests to remove duplicated resource loading
code.
Change-Id: Idb2e962fe5cae39b70cc8cf16053d0a253f4fac0
Issue-ID: AAI-2121
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Fix a bug that masked differences between expected and actual XML files.
This affects JUnit tests only.
Change-Id: I72c779c008baa9fba52c09a0751cdd25bdc0e5cc
Issue-ID: AAI-1991
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Simplify the JUnit testing for the YAML file extractor and compare the
actual and expected files using Strings (with line endings normalized).
Change-Id: Ie78d3506511b4a1d5333c1b0b95a676bbc2ab5e2
Issue-ID: AAI-1991
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Create an InstanceGroup XML model for groups of the Service topology
template in the case where there is no Resource model generated.
Add a test CSAR file for a Service Proxy (an unsupported type).
Assert that the Service is associated with the instance-group Models.
Change-Id: If76bf7a1cfb960bc8692f1e136ee85176725915e
Issue-ID: AAI-1963
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Reorganize the Service and Resource Model generation code for
readability. Resort methods to put public before private.
Rename generateService() to generateAllArtifacts()
Reimplement this method such that the NodeTemplate list is iterated once
only. This is intended to simplify future changes to the code.
Change-Id: Ie0c6003eab99f42945747c6d79827881e05afc87
Issue-ID: AAI-1884
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Minor refactoring and reformatting of Java code using Eclipse.
Add private method mergeProperties() to replace duplicated code logic for
populating the Group model.
Change-Id: I1360bbbf5b065149028a94392dd530af9c9153e8
Issue-ID: AAI-1884
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Refactor existing code and add a Junit test for the relevant method.
Change-Id: I66703f1d2e93173df4676070faf66e289360609a
Issue-ID: AAI-1884
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Non-functional changes addressing whitespace inconsistencies.
Change-Id: Ife84f6b04bf8ce0204409d2f3708ab85b3a3caff
Issue-ID: AAI-1884
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Add a test CSAR file to ensure that the ArtifactGeneratorToscaParser method
processInstanceGroup() is covered, prior to refactoring.
Change-Id: I277b6721c8a406631d54716aa68b313b1937e5cf
Issue-ID: AAI-1884
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Use UTC for the Clock value that is passed to the Info Service as a
test, to avoid any Daylight Savings adjustments.
Change-Id: Id9cafdae6e63bd5908ffe8f61ca21c617e86b08b
Issue-ID: AAI-1766
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
The ZoneOffset was being applied twice, causing the number of hours
added to a test Clock to be calculated incorrectly only when Daylight
Savings changes were applied during the interval.
For example, the status report was showing 4 days 23 hrs instead of 5
days when the clocks had been put back an hour.
Change-Id: If6380a8901b2723018dd3a45fcd7df3ffa0168d4
Issue-ID: AAI-1766
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Generate models for Instance Groups (for specific supported types).
Process groups with a metadata type of CR or Configuration.
Add InstanceGroup Widget to the supported Widgets.
Add support for a group filter properties resource/file (with the
single property key "AAI.instance-group-types" which provides a
comma-separated list of supported types).
Add the System Propery groupfilter.config to define the file path.
Change-Id: I6153e6284965c57ae43291b1dc3ee4a1d11e6583
Issue-ID: AAI-1579
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Remove unnecessary data from the test input files. Only the TOSCA YAML
content is needed for testing Babel functionality.
Change-Id: I25a459f70a0ea6adb64aa87965044b63e2eeb273
Issue-ID: AAI-1250
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
New tests for extracting software versions.
Change-Id: I26a9d654d03154a1d026741e623c8f953946a5f4
Issue-ID: AAI-1250
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Simplify the code by introducing an Enum to store each of the test input
CSAR files. Add common functionality to this Enum class.
Change-Id: I3c44d7ec3b7808a193b8918c43cf0a9eb5369533
Issue-ID: AAI-1250
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
|
|
To simplify debugging and manual inspection of XML output files, use
meaningful strings in place of UUIDs in the Junit test properties.
Change-Id: If6721685d36c3959c946bd57a0872cbb1ce188ec
Issue-ID: AAI-1250
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Add test cases for both 0 and 2 VNF Configurations in the input CSAR file
Issue-ID: AAI-1250
Change-Id: I0cae09f876d7bbb08cbe48019220e1836e4b7fca
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
The SD-WAN test CSAR file is parseable using the sdc-tosca dependency
version 1.4.1 but it cannot be parsed using version 1.4.2 and above, as
there are missing data types leading to inheritance errors.
Correct the test CSAR file by adding the missing types. This has a
beneficial side-effect of increasing code coverage.
Issue-ID: AAI-1250
Change-Id: I41682b49d9d0a260a6feff05fda135949b46ec05
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Create additional TOSCA YAML content for the existing SD-WAN Service
CSAR input file, so that the VF Module processing code is invoked.
Issue-ID: AAI-1250
Change-Id: I24a842223154d52e1a4a19e5b9cd739b0ceee4f4
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Change-Id: I4138d1d60fe234949264f3c2d2e2156681e9075c
Issue-ID: AAI-1448
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Added code to check for null metadata.
Decomposed existing methods to avoid Sonar complexity warnings.
Renamed some variables for readability.
Change-Id: Id68be06bb5c105f45870a08f60a4ddc4dfbe5b09
Issue-ID: AAI-1448
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Issue-ID: AAI-1444
Change-Id: If25a2ea001fe7b43dbd14eed008a14e5dd8b3579
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Updated some Javadoc text for compatibility with Checkstyle settings.
Issue-ID: AAI-1444
Change-Id: I9d7541aa24d07e42d7d127f76b8576a7fa7184d4
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
The aai-schema version has changed from v13 to v14. Unit tests which
compare actual results with expected results are updated not to fail.
Change-Id: I464eec917d5062e21a5f9c41155fe86ca1e073b9
Issue-ID: AAI-1400
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Also correct formatting for Checkstyle and add Javadoc comments where
missing.
Issue-ID: AAI-1250
Change-Id: I614fd748fb288e6fc8f763f073e99a5067cbaac4
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
|
|
Added tests and made GeneratorUtil final class
Change-Id: I3e9b3fa22dff5c50fa37ad10ba0ddd8b9bbef2d9
Issue-ID: AAI-1334
Signed-off-by: awudzins <adam.wudzinski@nokia.com>
|
|
Change-Id: Ie67b85df855670974aa7939caf0f9afc3effe077
Issue-ID: AAI-1242
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Add support for Port Mirroring Configuration XML model generation from SDC TOSCA
Change-Id: I44718d20a53e343ee34ae47ef2bc35d49c862ddf
Issue-ID: AAI-1345
Signed-off-by: Lee, Tian (tl5884) <TianL@amdocs.com>
|
|
New tests to improve code coverage. Remove underscores from existing
Junit test method names.
Issue-ID: AAI-1250
Change-Id: I8d0d9c41d7a124cbedea69d64c4cd78ac6e4bcfa
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Move the String constants out of a common class and into the individual
classes where they are used. This eliminates a set of Sonar code smells
relating to non-standard ordering of declarations. It simplifies the
code by removing the need for an empty private constructor in the static
class (i.e. containing static methods only).
Additionally, simplify the AaiModelGenerator interface by removing the
static factory method (which is not currently required). If multiple
implementations are needed we can use Spring annotations in the future.
Issue-ID: AAI-1242
Change-Id: Ica03b66ae2fd899977093d11d3e23dc3f3c8f194
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Code reformatting to address Sonar code smells, excluding the cyclomatic
complexity errors which will require some heavier refactoring.
Issue-ID: AAI-1242
Change-Id: I0f2502c8038b1e70f53f3b82b9d4d0761d9137cc
Signed-off-by: mark.j.leonard <mark.j.leonard@gmail.com>
|
|
Change-Id: Iae3139b33e315fae0c205fd7e0df67554d91cd5b
Issue-ID: AAI-1126
Signed-off-by: Lee, Tian (tl5884) <TianL@amdocs.com>
|