summaryrefslogtreecommitdiffstats
path: root/adapters/mso-adapter-utils
AgeCommit message (Collapse)AuthorFilesLines
2019-05-01Fixup handling of multicloud post responseEric Multanen2-63/+36
Make the handling of the multicloud post response more flexible. Add additional parameters that may come back. Change-Id: I0a5c7016f11dbfe832c81e2fcafc398a998b622b Issue-ID: SO-1833 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com>
2019-05-01build sndc and user directives in groovyEric Multanen1-1/+1
Fill out the sdnc_directives and user_directives used by the multicloud vnf plugin adapter when invoked via the groovy path. Change-Id: Ia11680be682b38756f188c71e3e000bc21c15aa9 Issue-ID: SO-1822 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com>
2019-04-26Fix multicloud query of non-existant stackEric Multanen1-1/+1
Fix handling of Not Found status for multicloud plugin query of a workload. Change-Id: Ie33b8728bf71fbcf0eaaa6496520351404928a36 Issue-ID: SO-1821 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com>
2019-04-11corrected inlucde filter for formatterBenjamin, Max (mb388a)1-146/+146
all pom.xml files now have two spaces validation is on for pom.xml files Change-Id: I424ea2e4d6a549f468792e5f90a43f3a97e6c954 Issue-ID: SO-1781 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-04-11Update multicloud plugin GET handlingEric Multanen7-33/+206
Supports multicloud API query by workload name or id. Gets workload details e.g. stack outputs, etc. To be used to fill in inputs for vfmodule that has a volume group or base module. Change-Id: If45783e82c2a209d3385be1b689a02a05baf9922 Issue-ID: SO-1445 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com>
2019-04-08Replaced all tabs with spaces in java and pom.xmlBenjamin, Max (mb388a)77-6505/+5989
Added in maven plugins to enforce coding style rules Added in eclipse java formatting xml Change-Id: I3727bbf4ce8dc66abfd8ad21b6cfd0890c5d3ff0 Issue-ID: SO-1765 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-04-08Query param to pull back nested stack informationBenjamin, Max (mb388a)1-3/+3
Add Query param to pull back nested stack information Change-Id: Idf83291107e2ef7e86bb2de914469b0401eda0ac Issue-ID: SO-1760 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-04-08Fixed recent Sonar blocker issuesr.bogacki1-1/+3
Fixed blockers according to Sonar analysis. Change-Id: Ib068b586cd72c1634780220ac5498e1962dee434 Issue-ID: SO-1734 Signed-off-by: Robert Bogacki <r.bogacki@samsung.com>
2019-04-06Add tenantId to multicloud request headerEric Multanen1-6/+10
The multicloud API can take the tenantId as an item in the header. Add the tenantId to the request headers of the multicloud plugin. Change-Id: I7ff11cd52eea429e0c694092b006887f13de2fda Issue-ID: SO-1446 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com>
2019-04-05Merge "Fixed Sonar blocker issues"Steve Smokowski2-8/+27
2019-04-05Fixed Sonar blocker issuesr.bogacki2-8/+28
Fixed blockers according to Sonar analysis. Added tests for fixed issues. Change-Id: I8e259147082d722961048454fae9484cc0d8b0a8 Issue-ID: SO-1734 Signed-off-by: Robert Bogacki <r.bogacki@samsung.com>
2019-04-04Call multicloud aai update from mc vnf pluginEric Multanen2-9/+117
After successful vfmodule create, invoke the multicloud api to trigger update in aai. Change-Id: I3f6ceee7a8ea5f907fefcbe1a57ba35b9a666cb1 Issue-ID: SO-1444 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com>
2019-04-03if audit fails write sub interface data to a aiBenjamin, Max (mb388a)1-0/+2
added logic to write sub interface information from openstack to a&ai when audit fails to find it Change-Id: I24266812dc60eb69bfd90e3e5b34113e9fd8f4f4 Issue-ID: SO-1737 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-04-02Construct multicloud infra_workload endpointEric Multanen3-12/+25
Use the cloudOwner and cloudRegion to construct the multicloud endpoint for the multicloud VNF plugin adapter. Use configuration to obtain the MSB IP and port number. Stop using the cloud sites catalog DB since there is only a single endpoint required talking to multicloud. Change-Id: I0e9b45a51b6e36f4782226f851e7d01de7f1b133 Issue-ID: SO-1447 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com>
2019-04-01Merge "JUnit tests for MsoMulticloudUtils"Steve Smokowski1-0/+35
2019-04-01replace all fixed wiremock portsBenjamin, Max (mb388a)8-99/+158
trying to get the tests that can be threaded to pass started to remove fixed port references Change-Id: I7bfe067a8f36c908039700646571681321e9a6f5 Issue-ID: SO-1676 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-04-01JUnit tests for MsoMulticloudUtilsr.bogacki1-0/+35
Increased junit tests coverage according to Sonar analyses. Added missing tests to deleteStack, queryStack, updateVdu and deleteVdu. Change-Id: I529725cfbe9be7cbdae9a197d39cd6a426ddb688 Issue-ID: SO-1692 Signed-off-by: Robert Bogacki <r.bogacki@samsung.com>
2019-03-28sonar blocker fixesLukasz Muszkieta3-21/+25
Change-Id: I7a61470291e05286cce0aa4e35c2f4068c4319fb Issue-ID: SO-1490 Signed-off-by: Lukasz Muszkieta <lukasz.muszkieta@nokia.com>
2019-03-26Eliminated printStackTrace() callsWitold Ficio Kopel2-2/+2
Eliminated calls to printStackTrace() on Throwable as they go to stdout and are not handled by logger. Occurences has been replaced by calls to logger or modifications to nearby logger calls (Throwable passed as last parameter). Occurences in unit test classes left without modification. Change-Id: I6a771d60a3ea69ceecc29bb21358e565aa5ce101 Issue-ID: LOG-631 Signed-off-by: Witold Ficio Kopel <w.kopel@samsung.com>
2019-03-22Multicloud VNF adapter use updated multicloud APIEric Multanen5-12/+92
Update the Multicloud plugin adapter to use the the enhanced multicloud infra_workload API. Mainly involves adding the user_directives and the vf-module model IDs to the call. Change-Id: I7ab78a8a304dbd61a5743ec67bb839037861ef9d Issue-ID: SO-1446 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com>
2019-03-21Merge "Adjust audit to use device_id to find nova server"Steve Smokowski1-12/+57
2019-03-20Adjust audit to use device_id to find nova serverBenjamin, Max (mb388a)1-12/+57
Adjust audit to use device_id to find nova server Change-Id: If060b68ba480b0750e66a7fe26a6fa72382dcdd5 Issue-ID: SO-1677 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-03-19Add cloudOwner to VNF adapter callEric Multanen8-64/+111
The BPMN layer has the CloudRegion which includes the CloudOwner attribute, but this is not passed to the VNF adapter layer. Calls to the Multicloud infrastructure workload need the CloudOwner as well. This patch adds CloudOwner to the VNF adapter API. While the intended usage is primarily for the multicloud adapter, it touches a log of other files - though those do not make use of it at this point. Change-Id: I88028096fbd84fc3fe5d53786c70b3c8806bb711 Issue-ID: SO-1447 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com>
2019-03-18Removed MsoLogger classr.bogacki7-99/+81
Bye bye MsoLogger class. Extracted constants to separated classes. Fixed imports. Change-Id: I7c8e0527e7dbd097d3ea93b9dab279354652da47 Issue-ID: LOG-631 Signed-off-by: Robert Bogacki <r.bogacki@samsung.com>
2019-03-13Openstack adapter can't resolve HEAT parameterBenjamin, Max (mb388a)3-4/+141
only cast to Element if value is of that type added XmlAccessorType annotations to classes map of string, object now correctly maps with jaxb Null comma delimited lists can convert to null as well Handle null values all types in input parameters map. Change-Id: Ic46ed31c05b8f8551d39b2267ae731829abfc1f0 Issue-ID: SO-1617 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-03-13Merge changes Id0369478,I82d8306fSteve Smokowski1-1/+1
* changes: Minior Change - Licence Statement Junit Class added for ObjectFactory.java
2019-03-08only convert object type json when StringBenjamin, Max (mb388a)4-12/+43
only convert object type json when input is a String Change-Id: I465dfe905f5d85de583b6232640dc4dc13a09c7a Issue-ID: SO-1610 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-03-07Minior Change - Licence StatementSudarshan Kumar1-1/+1
Minior Change - Licence Statement Issue-ID: SO-1576 Change-Id: Id03694789d6aa22d6e656204f875f4b5d8cd1700 Signed-off-by: Sudarshan Kumar <sudars19@in.ibm.com>
2019-03-06improvements to audit inventory featureBenjamin, Max (mb388a)2-1/+2
Adjust test data to add tenant mapping Remove unused unit test already renamed Update logic, to pass hostname not pservername remove unused file that has been refactored Add project to ignore, remove class Address issues in comments on pull request Remove logging that is not needed, used UPdate BPMN to use Boolean Value, change timings Adjust BPMN to not hit deadlock scenario put error message in execution before checking rollback - removed extra code for vnf resource processing found in onap environment. Fix improper use of inclusive gateway causing deadlock Fix flakey unit tests from ONAP Remove qualifier on bean, as it breaks callbacks Adjust pom version of external camunda client Fix polling timers to be more reasonable Updated Junit test for delete vf module in onap. Changed auditInventoryNeeded variable to a boolean to prevent bpmn from erroring out in the event this variable is not found on the execution. Update logic to support writing of self link Change-Id: I2f784a0a58a09f303775282c9be6019031668570 Issue-ID: SO-1597 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-03-04Junit added for KeystoneAuthHolder.javaSudarshan Kumar1-0/+59
Junit added for KeystoneAuthHolder.java Issue-ID: SO-1576 Change-Id: Ib313d6a3aa01da3fc7292b2cae4ba7b0a03ebce6 Signed-off-by: Sudarshan Kumar <sudars19@in.ibm.com>
2019-03-01vnf spin up gr api vnf s base module failsBenjamin, Max (mb388a)5-35/+150
map object representations of json back to json strings marshal all objects to json strings before sending all input params converted to Map<String, Object> Updated userParams map from HashMap<String, String> to Map<String, Object> as HashMap<String, String> userParams was causing VNF spin up to fail. Input json in Userparams was not accepted as a valid json format. Updated other files that were affected by this change. Change-Id: I0c00fc00c4c11b54ace4df7be8d5bfc80d41d130 Issue-ID: SO-1582 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-02-26Remove MsoLogger from 'mso-adapter-utils'k.kazak11-618/+709
Removed MsoLogger from adapters ('mso-adapter-utils') Replaced MsoLogger with plain slf4j Refactored login output Fixed imports Change-Id: I5805427f3d6870a35f523934ceee73f17d4e130d Issue-ID: LOG-631 Signed-off-by: k.kazak <k.kazak@samsung.com>
2019-02-22fix potential nullpointer from sonark.kazak2-21/+144
MsoMulticloudUtils: multicloudClient may be null throw MsoException if it is null (instead of NullPointer) removed unnecessary StackInfo object creation using format specifiers for a logger instead of String concatenation removed else block to make the code easier to read Added tests for the method Change-Id: I80d2e0ba2ef2d20c488cdfcf103d9cfa5784ab65 Issue-ID: SO-1516 Signed-off-by: k.kazak <k.kazak@samsung.com>
2019-02-15fix sonar critical bugk.kazak4-23/+83
MsoHeatUtils: remove unnecessary heatClient check for null 1. sonar assumes that heatClient is nullable and NullPointer may be thrown in line 309 2. heatClient is never null: method creates a new object or throws Exception MsoHeatUtilsTest: added tests for getHeatClient and createStack methods BaseTest: made CloudIdentity and CloudSite getters protected for other tests to use them StubOpenStack: added stubs for getStack and unsuccessful authorization removed unused imports Change-Id: Ie62c89f55d1894df48d9cc4d14760d36e96c4cb2 Issue-ID: SO-1516 Signed-off-by: k.kazak <k.kazak@samsung.com>
2019-02-13Remove un-needed cacheing layer for OS ClientsBenjamin, Max (mb388a)3-147/+2
Remove un-needed cacheing layer for OS Clients Change-Id: I7fbb6e23a3c34f65286202ec4dad1fb051991cf0 Issue-ID: SO-1500 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-02-01compare resources from openstack to aaiBenjamin, Max (mb388a)2-215/+279
Address Review comments on pull request Update Unit test to have proper variable for testing update logic inside bpmn to reflect proper variable Update unit test to check property for audit Add flag to turn on and off audit behavior Add license headers, remove un-used files Update Building Block Tests and Activity Names Fix additional unit tests in so-bpmn-tasks layer Fix broken Junit Test, and correct Bug in if statement Add annotation to ignore class under test profile Additional bug fixes and unit tests for classes Add Additional JUNITS, add more sample data Add Openstack Audit functionality to Adapter Change-Id: I0492063271e991eefc608b56336a5cdf1d5a7778 Issue-ID: SO-1456 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-01-28Merge 'origin/casablanca' into masterBenjamin, Max (mb388a)1-51/+65
Issue-ID: SO-1435 Change-Id: If065ef5c91e769452fd6701fa6c28a23b4bdf2b2 Signed-off-by: Smokowski, Steve (ss835w) <ss835w@us.att.com>
2019-01-24Removed deprecated Matcher importsBenjamin, Max (mb388a)1-1/+1
replaced org.mockito.Matchers with ArgumentMatchers Change-Id: I2feb4d4fb314cd14aca0719c4cc29b1a0510cbf7 Issue-ID: SO-1413 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-01-15MsoTenantUtilsFactoryTest unit testsMichal Kabaj1-2/+34
-added new test cases for factory class Change-Id: Iddd221d1ff5fa6748657b635bc07b6c795b8b9d8 Issue-ID: SO-1339 Signed-off-by: Michal Kabaj <michal.kabaj@nokia.com>
2019-01-14Add missing license headersBenjamin, Max (mb388a)5-1/+101
add headers to files which were missing them Issue-ID: SO-1390 Change-Id: I6c754f72c5d1ef6485d6343aae4b994120901d08 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2019-01-11Add junit tests for MsoCloudifyUtilsLukasz Muszkieta1-1/+94
Change-Id: If12ed6350306cd489aa8b1744a513875b42540c3 Issue-ID: SO-430 Signed-off-by: Lukasz Muszkieta <lukasz.muszkieta@nokia.com>
2019-01-11junits for MsoTenantUtilsFactoryTomasz Gwozdecki1-0/+16
-Added new test for MsoTenantUtilsFactory Change-Id: I9ba756a1f1c569dc7d0c1528272cca1ccfe3aad4 Issue-ID: SO-1339 Signed-off-by: Tomasz Gwozdecki <tomasz.gwozdecki@nokia.com>
2019-01-04HttpClientFactory to create HttpClient instancesMichal Kabaj1-10/+6
-Replace constructor calls with existing factory -Add create methods to factory for each required Media Type Change-Id: Ibd03c10230c87a0413c0ec529e0ea9ac800444f9 Issue-ID: SO-1344 Signed-off-by: Michal Kabaj <michal.kabaj@nokia.com>
2018-12-21Fixup multicloud log exceptions part 2Eric Multanen1-12/+12
One more fixup for logging calls which would have an exception. Change-Id: Id29324309400be5e4fdcf25cf8dd29929d10e6c1 Issue-ID: SO-1336 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com>
2018-12-20Fixup multicloud log exceptions and error casesEric Multanen1-17/+24
Fix log calls which would have an exception. Throw and mso exception when call to multicloud fails to create a stack. Change-Id: Ib103c6f4420e444734bbb715699eb57ffc110925 Issue-ID: SO-1336 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com>
2018-12-13junits for MsoTenantUtilsFactoryTomasz Gwozdecki1-0/+38
-Added new test for MsoTenantUtilsFactory Change-Id: I06719de861fc5d01bb5a8b71d5444eefd7b8b766 Issue-ID: SO-1339 Signed-off-by: Tomasz Gwozdecki <tomasz.gwozdecki@nokia.com>
2018-12-05moved all ecomp.mso properties to org.onap.soKalkere Ramesh, Sharan (sk720x)4-11/+28
moved all ecomp.mso properties to org.onap.so Change-Id: I55bd57d1c1d1dca065575c03d3c0b8f83aa4594d Issue-ID: SO-1278 Signed-off-by: Kalkere Ramesh, Sharan (sk720x) <sk720x@att.com>
2018-11-29Fix multicloud with no oof or sdnc directivesEric Multanen1-20/+27
Allow the multicloud adapter to work if no oof or sdnc directives are passed in - use an empty json node - e.g. {}. Change-Id: Ia701051de8a3da314957e4a4085963af6aff16b6 Issue-ID: SO-1247 Signed-off-by: Eric Multanen <eric.w.multanen@intel.com> Signed-off-by: Marcus G K Williams <marcus.williams@intel.com>
2018-11-27Remove all usage of AlarmLoggerBenjamin, Max (mb388a)6-37/+33
Fix broken UT from removing alarm logger fixed compilation and merge issues Remove all usage of AlarmLogger Change-Id: Ic87abd51423274570bfca0ed976d9642a91a843d Issue-ID: SO-1229 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
2018-11-21Add Keystone V3 SupportBenjamin, Max (mb388a)10-77/+410
update JEL with explicit getVariable call set project object into scope object add camunda properties as defaults in application.yaml added exception handling to keystone v3 case added in password method to identity object initial commit of keystone v3 auth support updated json property values with "_name" added new columns to cloud identity Change-Id: Ie08e9893c34d7199197efdb21fe4dd5413b25f44 Issue-ID: SO-1225 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>